|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.novell.admin.ns.NSObject | +--com.novell.admin.ns.DefaultNSObject
Memory model for objects stored in a namespace.
This model is provided for applications to access and modify all elements associated with a directory object. Elements such as attributes, flags, and schema for an object should be retrieved using this class.
Field Summary | |
protected java.util.Hashtable |
addedAttributeDefinitions
Running list of newly added attribute definitions. |
protected AdminNamespace |
namespace
Namespace that can be used to get class definition |
protected com.novell.application.console.snapin.ObjectEntry |
objectEntry
The associated ObjectEntry. |
Fields inherited from class com.novell.admin.ns.NSObject |
addedAttributes,
attributes,
classDefinition,
deletedAttributes,
modifiedAttributes,
propertyListeners,
revision |
Constructor Summary | |
protected |
DefaultNSObject(com.novell.application.console.snapin.ObjectEntry objEntry,
java.util.Vector attributes,
long rev)
Constructor. |
Method Summary | |
void |
addAttribute(ObjectAttribute attr)
Adds a newly valued attribute to the object. |
boolean |
addAuxiliaryClassDefinition(ClassDefinition classDef,
ObjectAttribute[] attrs)
Adds an auxiliary class Definition. |
void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Adds this listener to the listener list for this object. |
protected void |
checkAdd(ObjectAttribute attr,
boolean isForAuxClass)
Checks to make sure an attribute can be added to this object. |
void |
clearAddedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to add. |
void |
clearAddedAttributeDefinitions()
Removes an attribute from the attributes to add. |
void |
clearDeletedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to delete. |
void |
clearModifiedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to modify. |
NSObject |
clone(com.novell.application.console.snapin.ObjectEntry newIdentity)
Creates an exact duplicate of this NSObject but gives it a new identity. |
boolean |
deleteAttribute(java.lang.String attrName)
Deletes a currently valued attribute of this object. |
boolean |
deleteAuxiliaryClassDefinition(ClassDefinition classDef)
Deletes an auxiliary class definition. |
java.util.Hashtable |
getAddedAttributeDefinitions()
Retrieves the attributes that have been added to the object. |
java.lang.String[] |
getAddedAttributes()
Retrieves the attributes that have been added to the object. |
ObjectAttribute |
getAttribute(java.lang.String attrName)
Retrieves a specific attribute of this object. |
java.lang.String[] |
getAttributes()
Retrieves the names of the valued attributes of the object. |
ClassDefinition[] |
getClassDefinitions()
Retrieves the schema class definition for the object. |
java.lang.String[] |
getDeletedAttributes()
Retrieves the attributes that have been deleted from the object. |
java.lang.String[] |
getMandatoryAttributes()
Retrieves the mandatory attributes of the object. |
java.lang.String[] |
getModifiedAttributes()
Retrieves the attributes that have been modified in the object. |
com.novell.application.console.snapin.ObjectEntry |
getObjectEntry()
Retrieves the object entry representation of the object. |
java.lang.String[] |
getOptionalAttributes()
Retrieves the optional attributes of the object. |
long |
getRevision()
Retrieves the revision of the object. |
java.lang.String[] |
getUnvaluedAttributes()
Retrieves the names of the attributes that are not valued. |
boolean |
isAttributeMandatory(java.lang.String attrName)
Checks to see if a particular attribute is mandatory for the Object Entry's schema class or its associated auxiliary classes. |
boolean |
isAttributeOptional(java.lang.String attrName)
Checks to see if a particular attribute is optional for the Object Entry's schema class or its associated auxiliary classes. |
boolean |
isNamedBy(java.lang.String attrName)
Checks to see if a particular attribute is a naming for the Object Entry's schema class or its associated auxiliary classes. |
void |
propertyChange(java.beans.PropertyChangeEvent event)
Callback for attribute modifications. |
void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes this listener from the listener list for this object. |
protected void |
setClassDefinition()
Sets the class definition for this object. |
Methods inherited from class com.novell.admin.ns.NSObject |
clone |
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
protected com.novell.application.console.snapin.ObjectEntry objectEntry
protected java.util.Hashtable addedAttributeDefinitions
protected AdminNamespace namespace
Constructor Detail |
protected DefaultNSObject(com.novell.application.console.snapin.ObjectEntry objEntry, java.util.Vector attributes, long rev)
objEntry
- The object entry representation.attributes
- Vector of ObjectAttributes or Strings if the attributes
are to be read later.rev
- revision number of the object.Method Detail |
public void addAttribute(ObjectAttribute attr) throws NamespaceException
attr
- The valued attribute to be added.This may be one of the following conditions.
public ObjectAttribute getAttribute(java.lang.String attrName)
attrName
- The name of the attribute that is to be retrieved.public boolean deleteAttribute(java.lang.String attrName) throws NamespaceException
attr
- The attribute to be deleted from the object.public java.lang.String[] getAddedAttributes()
public java.util.Hashtable getAddedAttributeDefinitions()
public java.lang.String[] getAttributes()
public java.lang.String[] getMandatoryAttributes()
public java.lang.String[] getOptionalAttributes()
public java.lang.String[] getUnvaluedAttributes()
public ClassDefinition[] getClassDefinitions()
public java.lang.String[] getDeletedAttributes()
public java.lang.String[] getModifiedAttributes()
public com.novell.application.console.snapin.ObjectEntry getObjectEntry()
public long getRevision()
public NSObject clone(com.novell.application.console.snapin.ObjectEntry newIdentity) throws NamespaceException
newIdentity
- The ObjectEntry whose identity is assumed.public boolean addAuxiliaryClassDefinition(ClassDefinition classDef, ObjectAttribute[] attrs) throws NamespaceException
classDef
- The class definition to add.attrs
- The attributes to add.
The only attributes that will be added are those that are not currently valued. If attributes are valued, please modify the value instead of trying to add the attribute.
public boolean deleteAuxiliaryClassDefinition(ClassDefinition classDef) throws NamespaceException
classDef
- The class definition to be deleted.public void propertyChange(java.beans.PropertyChangeEvent event)
event
- The property change event that was registered for.public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
listener
- The listener to be added.public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
listener
- The listener to be removed.public void clearAddedAttribute(java.lang.String attrName)
attr
- The valued attribute to be removed from the add list.public void clearAddedAttributeDefinitions()
attr
- The valued attribute to be removed from the add list.public void clearDeletedAttribute(java.lang.String attrName)
attrName
- The valued attribute to be removed from the delete list.public void clearModifiedAttribute(java.lang.String attrName)
attrName
- The valued attribute to be removed from the modify list.protected void checkAdd(ObjectAttribute attr, boolean isForAuxClass) throws NamespaceException
attr
- The name of the attribute.isForAuxClass
- Attribibue is being added due to an Aux class association.public boolean isAttributeMandatory(java.lang.String attrName)
attrName
- Name of the attribute to look for.public boolean isAttributeOptional(java.lang.String attrName)
attrName
- Name of the attribute to look for.public boolean isNamedBy(java.lang.String attrName)
attrName
- Name of the attribute to look for.protected void setClassDefinition()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |