Document directory and improve mapping with ACR
[lgpl/argeo-commons.git] / org.argeo.util / src / org / argeo / util / directory / HierarchyUnit.java
index d35557784dd1f2e00ef5f1873c68b45a764f1721..1acd34f487278a5e1c06a2d978f97980abc75aa0 100644 (file)
@@ -4,12 +4,24 @@ import java.util.Dictionary;
 
 /** A unit within the high-level organisational structure of a directory. */
 public interface HierarchyUnit {
+       /** Name to use in paths. */
        String getHierarchyUnitName();
 
+       /**
+        * The parent {@link HierarchyUnit}, or <code>null</code> if a
+        * {@link Directory}.
+        */
        HierarchyUnit getParent();
 
+       /** Direct children {@link HierarchyUnit}s. */
        Iterable<HierarchyUnit> getDirectHierarchyUnits(boolean functionalOnly);
 
+       /**
+        * Whether this is an arbitrary named and placed {@link HierarchyUnit}.
+        * 
+        * @return <code>true</code> if functional, <code>false</code> is technical
+        *         (e.g. People, Groups, etc.)
+        */
        boolean isFunctional();
 
        /**
@@ -18,7 +30,9 @@ public interface HierarchyUnit {
         */
        String getBase();
 
+       /** The related {@link Directory}. */
        Directory getDirectory();
 
+       /** Its metadata (typically LDAP attributes). */
        Dictionary<String, Object> getProperties();
 }