|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--javax.swing.tree.DefaultMutableTreeNode
|
+--org.PingOO.DLAI.lib.directorytree.DirectoryComponent
Common abstract class for all directory components.
DefaultMutableTreeNode, Serialized Form| Inner classes inherited from class javax.swing.tree.DefaultMutableTreeNode |
javax.swing.tree.DefaultMutableTreeNode.BreadthFirstEnumeration,
javax.swing.tree.DefaultMutableTreeNode.PathBetweenNodesEnumeration,
javax.swing.tree.DefaultMutableTreeNode.PostorderEnumeration,
javax.swing.tree.DefaultMutableTreeNode.PreorderEnumeration |
| Field Summary | |
protected java.util.Hashtable |
accessTable
Defines the access rights of the current user on the visible fields. |
protected java.util.Vector |
attributeVector
Vector of the component's attributes (keys). |
static java.lang.String |
CREATION_DATE_KEY
|
static java.lang.String |
DESCRIPTION_KEY
|
static java.lang.String |
DN_SEPAPATOR
|
protected static java.lang.String[] |
EMPTY_ARRAY_ATTRIBUTE
|
static java.lang.String |
EXPIRATION_DATE_KEY
|
protected java.util.Hashtable |
exportationTable
Defines if a field is exportable. |
static java.lang.String |
FIELD_SEPAPATOR
|
static java.lang.String |
ICON_KEY
|
protected java.util.Hashtable |
labelTable
Contains the label (titleKey in fact) associated with each ressource. |
static java.lang.String |
MODIFICATION_DATE_KEY
|
protected boolean |
modified
Indicates if the componet has been modified. |
static java.lang.String |
OBJECT_CLASS_KEY
|
static java.lang.String |
PROGRAM_KEY
|
protected java.util.Vector |
requiredVector
Vector of required fields. |
static java.lang.String |
RESOURCE_KEY
|
protected boolean |
upToDate
Indicates if the component have all is up to date attributes. |
protected java.util.Hashtable |
valueTable
Contains the values associated with each resource. |
| Fields inherited from class javax.swing.tree.DefaultMutableTreeNode |
allowsChildren,
children,
EMPTY_ENUMERATION,
parent,
userObject |
| Constructor Summary | |
DirectoryComponent(java.lang.String name,
java.lang.String type)
Creates a tree node with no parent, no children, but which allows children, and initializes it with the specified user object. |
|
DirectoryComponent(java.lang.String name,
java.lang.String type,
boolean allowsChildren)
Creates a tree node with no parent, no children, initialized with the specified user object, and that allows children only if specified. |
|
| Method Summary | |
void |
add(javax.swing.tree.MutableTreeNode newChild)
Removes newChild from its parent and makes it a child of this node by adding it to the end of this node's child array. |
java.util.Enumeration |
attributes()
Returns an enumeration of all attributes in this node. |
abstract java.util.Enumeration |
children(boolean recursiveSearch)
Returns the list of all child of the same class this node allows. |
abstract java.util.Enumeration |
children(java.lang.Class objectClass)
Returns the list of all child of the same class this node allows. |
abstract java.util.Enumeration |
children(java.lang.Class objectClass,
boolean recursiveSearch)
Returns the list of all child of the same class this node allows. |
boolean |
getAccessValue(java.lang.String attributeKey)
|
java.util.Hashtable |
getAccessValues()
Returns a copy of this node's access table. |
java.lang.String |
getAttributeLabel(java.lang.String attributeKey)
Returns the default label associated with a given value. |
java.util.Hashtable |
getAttributeTextKeys()
Returns a copy of this node's attributes' labels table. |
java.lang.Object |
getAttributeValue(java.lang.String attributeKey)
Returns one of this node's attribute's value . |
java.util.Hashtable |
getAttributeValues()
Returns a copy of this node's attributes table. |
java.lang.String |
getDN()
Returns the dinstinguished name of this component. |
boolean |
getExportationValue(java.lang.String attributeKey)
|
java.lang.String |
getName()
Return the name of this component. |
static java.lang.String |
getNewDN(DirectoryComponent parentComponent,
DirectoryComponent childComponent)
Return a new complete DN for a new component that is about inserted in the tree. |
java.lang.String |
getRDN()
Returns the relative dinstinguished name of this component. |
abstract java.lang.String |
getType()
Returns the type of this component. |
boolean |
hasRequiredAttributes()
Tests if this component has the required attributes. |
void |
insert(javax.swing.tree.MutableTreeNode newChild,
int childIndex)
Removes newChild from its present parent (if it has a parent), sets the child's parent to this node, and then adds the child to this node's child array at index childIndex.newChild must not be null and must not be an ancestor of this node. |
boolean |
isAccessible()
|
boolean |
isModified()
Indicates if this node has been modified. |
boolean |
isUpToDate()
Indicates if this node has up to date informations. |
void |
prepareMessage(MessageHashtable message)
|
void |
remove(javax.swing.tree.MutableTreeNode aChild)
Removes aChild from this node's child array, giving it a null parent. |
java.util.Enumeration |
requiredAttributes()
Returns an enumeration of the required attributes for this node. |
void |
setAccessValue(java.lang.String attributeKey,
boolean value)
|
void |
setAccessValues(java.util.Hashtable updatedTable)
|
void |
setAccessValues(MessageHashtable updatedTable)
|
void |
setAttributeValue(java.lang.String attributeKey,
java.lang.Object value)
Sets one attribute of this component. |
void |
setAttributeValues(java.util.Hashtable updatedTable)
Sets the attributes of this component. |
void |
setAttributeValues(MessageHashtable updatedTable)
Sets the attributes of this component. |
void |
setDefaultAccess()
Sets the defautl access on this node (read-only access. |
protected void |
setDefaultExportation()
|
void |
setExportationValue(java.lang.String attributeKey,
boolean value)
|
void |
setModified(boolean b)
Sets if this node has been modified. |
void |
setName(java.lang.String name)
Sets the name of this component. |
void |
setUpToDate(boolean b)
Sets if this node has up to date informations. |
| Methods inherited from class javax.swing.tree.DefaultMutableTreeNode |
|
| Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
wait,
wait,
wait |
| Field Detail |
protected static final java.lang.String[] EMPTY_ARRAY_ATTRIBUTE
public static final java.lang.String DN_SEPAPATOR
public static final java.lang.String FIELD_SEPAPATOR
public static final java.lang.String OBJECT_CLASS_KEY
public static final java.lang.String CREATION_DATE_KEY
public static final java.lang.String EXPIRATION_DATE_KEY
public static final java.lang.String MODIFICATION_DATE_KEY
public static final java.lang.String RESOURCE_KEY
public static final java.lang.String PROGRAM_KEY
public static final java.lang.String ICON_KEY
public static final java.lang.String DESCRIPTION_KEY
protected boolean upToDate
protected boolean modified
protected final java.util.Vector attributeVector
protected final java.util.Vector requiredVector
protected final java.util.Hashtable labelTable
protected final java.util.Hashtable valueTable
protected final java.util.Hashtable accessTable
protected final java.util.Hashtable exportationTable
| Constructor Detail |
public DirectoryComponent(java.lang.String name,
java.lang.String type)
name - This component's name.type - The type of this component.
public DirectoryComponent(java.lang.String name,
java.lang.String type,
boolean allowsChildren)
name - This component's name.type - The type of this component.allowsChildren - If true the component will allow chilfren to be added, if false, it will not be possible to add children.| Method Detail |
public void add(javax.swing.tree.MutableTreeNode newChild)
newChild - The noode to add as a child of this node.
public void insert(javax.swing.tree.MutableTreeNode newChild,
int childIndex)
throws java.lang.ArrayIndexOutOfBoundsException,
java.lang.IllegalArgumentException,
java.lang.IllegalStateException
newChild from its present parent (if it has a parent), sets the child's parent to this node, and then adds the child to this node's child array at index childIndex.newChild must not be null and must not be an ancestor of this node.newChild - The MutableTreeNode to insert under this node.childIndex - The index in this node's child array where this node is to be inserted.null or is an ancestor of this node.public void remove(javax.swing.tree.MutableTreeNode aChild)
aChild - A child of this node to remove.public abstract java.lang.String getType()
public java.lang.String getName()
public void setName(java.lang.String name)
name - The new name of this component.
public static final java.lang.String getNewDN(DirectoryComponent parentComponent,
DirectoryComponent childComponent)
null if the child component is null.public java.lang.String getRDN()
public java.lang.String getDN()
public abstract java.util.Enumeration children(boolean recursiveSearch)
recursiveSearch - If true look for all children under this node.public abstract java.util.Enumeration children(java.lang.Class objectClass)
objectClass - The class used to filter the children.
public abstract java.util.Enumeration children(java.lang.Class objectClass,
boolean recursiveSearch)
recursiveSearch - If true look for all children under this node.objectClass - The class used to filter the children.public final void prepareMessage(MessageHashtable message)
public void setAttributeValue(java.lang.String attributeKey,
java.lang.Object value)
attributeKey - The attribute's key.value - The new value for this attribute.public void setAttributeValues(MessageHashtable updatedTable)
updatedTable - The table that contains the new attributes for this object.public void setAttributeValues(java.util.Hashtable updatedTable)
updatedTable - The table that contains the new attributes for this object.public final java.lang.Object getAttributeValue(java.lang.String attributeKey)
attributeKey - The attribute's key.null if the key is unknown to this node or if the value is empty.public final java.lang.String getAttributeLabel(java.lang.String attributeKey)
attributeKey - The attribute's key.null if the key is unknown to this node or if the label is empty.public final java.util.Hashtable getAttributeValues()
public final java.util.Hashtable getAttributeTextKeys()
public boolean hasRequiredAttributes()
true since the basic required attribute is the object class and all object has its own objectclass.public java.util.Enumeration attributes()
public java.util.Enumeration requiredAttributes()
public final void setDefaultAccess()
public boolean isAccessible()
public final java.util.Hashtable getAccessValues()
public void setAccessValues(MessageHashtable updatedTable)
public void setAccessValues(java.util.Hashtable updatedTable)
public final void setAccessValue(java.lang.String attributeKey,
boolean value)
public final boolean getAccessValue(java.lang.String attributeKey)
protected final void setDefaultExportation()
public final void setExportationValue(java.lang.String attributeKey,
boolean value)
public final boolean getExportationValue(java.lang.String attributeKey)
public final boolean isUpToDate()
true if this node has up to date informations, false otherwise.public final void setUpToDate(boolean b)
b - true if this node has up to date informations, false otherwise.public final boolean isModified()
true if this node has been modified, false otherwise.public final void setModified(boolean b)
b - true if this node has been modified, false otherwise.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||