]> git.argeo.org Git - lgpl/argeo-commons.git/blob - org.argeo.util/src/org/argeo/util/directory/HierarchyUnit.java
Append multiple exceptions in the same CmsFeedBack
[lgpl/argeo-commons.git] / org.argeo.util / src / org / argeo / util / directory / HierarchyUnit.java
1 package org.argeo.util.directory;
2
3 import java.util.Dictionary;
4
5 /** A unit within the high-level organisational structure of a directory. */
6 public interface HierarchyUnit {
7 /** Name to use in paths. */
8 String getHierarchyUnitName();
9
10 /**
11 * The parent {@link HierarchyUnit}, or <code>null</code> if a
12 * {@link Directory}.
13 */
14 HierarchyUnit getParent();
15
16 /** Direct children {@link HierarchyUnit}s. */
17 Iterable<HierarchyUnit> getDirectHierarchyUnits(boolean functionalOnly);
18
19 /**
20 * Whether this is an arbitrary named and placed {@link HierarchyUnit}.
21 *
22 * @return <code>true</code> if functional, <code>false</code> is technical
23 * (e.g. People, Groups, etc.)
24 */
25 boolean isFunctional();
26
27 /**
28 * The base of this organisational unit within the hierarchy. This would
29 * typically be an LDAP base DN.
30 */
31 String getBase();
32
33 /** The related {@link Directory}. */
34 Directory getDirectory();
35
36 /** Its metadata (typically LDAP attributes). */
37 Dictionary<String, Object> getProperties();
38 }