public abstract class NSObject
extends java.lang.Object
implements java.lang.Cloneable, java.beans.PropertyChangeListener, java.io.Serializable
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.
| Modifier and Type | Field and Description |
|---|---|
protected java.util.Vector |
addedAttributes
Running list of newly valued attributes.
|
protected java.util.Hashtable |
attributes
Current list of mandatory and optional attributes.
|
protected java.util.Vector |
classDefinition
Class definition
|
protected java.util.Vector |
deletedAttributes
Running list of deleted attributes.
|
protected java.util.Vector |
modifiedAttributes
Running list of modified attributes.
|
protected java.util.Vector |
propertyListeners
List of registered Property Change Listeners
|
protected long |
revision
Revision of the object at the time of the directory read.
|
protected boolean |
shadowSign |
| Constructor and Description |
|---|
NSObject() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
addAttribute(ObjectAttribute attr)
Adds a newly valued attribute to the object.
|
abstract boolean |
addAuxiliaryClassDefinition(ClassDefinition classDef,
ObjectAttribute[] attrs)
Adds an auxiliary class Definition.
|
abstract void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Add this listener to the listener list for this object.
|
abstract void |
clearAddedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to add.
|
abstract void |
clearDeletedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to delete.
|
abstract void |
clearModifiedAttribute(java.lang.String attrName)
Removes an attribute from the attributes to modify.
|
java.lang.Object |
clone()
Creates an exact duplicate of this NSObject but discards all change info.
|
abstract NSObject |
clone(ObjectEntry newIdentity)
Creates an exact duplicate of this NSObject but give it a new identity.
|
abstract boolean |
deleteAttribute(java.lang.String attrName)
Deletes a currently valued attribute of this object.
|
abstract boolean |
deleteAuxiliaryClassDefinition(ClassDefinition classDef)
Deletes an auxiliary class Definition.
|
abstract java.lang.String[] |
getAddedAttributes()
Retrieves the attributes that have been added to the object.
|
abstract ObjectAttribute |
getAttribute(java.lang.String attrName)
Retrieves a specific attribute of this object.
|
abstract ObjectAttribute |
getAttribute(java.lang.String attrName,
AdminNamespaceExceptionReference aneRef,
ObjectEntry serverOE)
exclude
Retrieves a specific attribute from this object.
|
abstract ObjectAttribute |
getAttribute(java.lang.String attrName,
int attrFlags,
AdminNamespaceExceptionReference aneRef,
ObjectEntry serverOE)
exclude
Retrieves a specific attribute from this object.
|
abstract java.lang.String[] |
getAttributes()
Retrieves the names of the valued attributes of the object.
|
abstract ClassDefinition[] |
getClassDefinitions()
Retrieves the schema class definition for the object.
|
abstract java.lang.String[] |
getDeletedAttributes()
Retrieves the attributes that have been deleted from the object.
|
abstract java.lang.String[] |
getMandatoryAttributes()
Retrieves the mandatory attributes of the object.
|
abstract java.lang.String[] |
getModifiedAttributes()
Retrieves the attributes that have been modified in the object.
|
abstract ObjectEntry |
getObjectEntry()
Retrieves the object entry representation of the object.
|
abstract java.lang.String[] |
getOptionalAttributes()
Retrieves the optional attributes of the object.
|
abstract long |
getRevision()
Retrieves the revision of the object.
|
boolean |
getShadowSign() |
abstract java.lang.String[] |
getUnvaluedAttributes()
Retrieves the names of the attributes that are not valued.
|
abstract boolean |
isAddPossible(ObjectAttribute attr,
boolean isForAuxClass)
Checks if the conditions are satisfied for adding an attributes.
|
abstract boolean |
isAttributeMandatory(java.lang.String attrName)
Checks to see if a particular attribute is mandatory for the Object
Entry's schema class or any associated auxiliary classes.
|
abstract boolean |
isAttributeOptional(java.lang.String attrName)
Checks to see if a particular attribute is optional for the Object
Entry's schema class or any associated auxiliary classes.
|
abstract boolean |
isNamedBy(java.lang.String attrName)
Checks to see if a particular attribute is a naming for the Object
Entry's schema class or any associated auxiliary classes.
|
abstract void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Remove this listener from the listener list for this object.
|
protected abstract void |
setClassDefinition()
Sets the class definition for this object.
|
void |
setShadowSign(boolean newSignValue) |
protected long revision
protected java.util.Vector classDefinition
protected java.util.Hashtable attributes
protected java.util.Vector addedAttributes
protected java.util.Vector deletedAttributes
protected java.util.Vector modifiedAttributes
protected java.util.Vector propertyListeners
protected boolean shadowSign
public void setShadowSign(boolean newSignValue)
public boolean getShadowSign()
public abstract void addAttribute(ObjectAttribute attr) throws NamespaceException
attr - The valued attribute to be added.NamespaceException - A condition occured which disallowed the add.public abstract ObjectAttribute getAttribute(java.lang.String attrName)
attrName - The name of the attribute that is to be retrieved.public abstract ObjectAttribute getAttribute(java.lang.String attrName, AdminNamespaceExceptionReference aneRef, ObjectEntry serverOE) throws SPIException, NamespaceException
attrName - The name of the attribute that is to be retrieved.aneRef - If null then any Exception that occurs will be thrown. If this parameter
is NOT null, then any Exception that occured will be returned in this
AdminNamespaceExceptionReference object and will NOT be thrown. Any ObjectAttribute
results (if any or if partial) will then be returned. This uses the USEEXCEPTIONREFERENCE
flag to return paritial results if available. If there are no ObjectAttribute results
then null will be returned.serverOE - the server to read from if read is necessary. If null then any server may be used.SPIExceptionNamespaceExceptionpublic abstract ObjectAttribute getAttribute(java.lang.String attrName, int attrFlags, AdminNamespaceExceptionReference aneRef, ObjectEntry serverOE) throws SPIException, NamespaceException
attrName - The name of the attribute that is to be retrieved.attrFlags - Any attribute specific flags which needs to be passed.
Currently supported flags are:
GETATTR_CONTEXTSTATICVALUES - to only get static values (members) for dynamic groups
GETATTR_READFROMWRITABLEREPLICA - to cause the read to go to a writeable replica
GETATTR_USEEXCEPTIONREFERENCE - Use the lower level protocol's API that returns
partial results (dynamic group timeout) instead
of throwing an exception.aneRef - If null then any Exception that occurs will be thrown. If this parameter
is NOT null, then any Exception that occured will be returned in this
AdminNamespaceExceptionReference object and will NOT be thrown. Any ObjectAttribute
results (if any or if partial) will then be returned. This uses the USEEXCEPTIONREFERENCE
flag to return paritial results if available. If there are no ObjectAttribute results
then null will be returned.serverOE - the server to read from if read is necessary. If null then any server may be used.SPIExceptionNamespaceExceptionpublic abstract boolean deleteAttribute(java.lang.String attrName)
throws NamespaceException
attrName - The attribute to be deleted from the object.NamespaceException - A condition occured that disallowed the delete.public abstract java.lang.String[] getAddedAttributes()
public abstract java.lang.String[] getAttributes()
public abstract java.lang.String[] getMandatoryAttributes()
public abstract java.lang.String[] getOptionalAttributes()
public abstract java.lang.String[] getUnvaluedAttributes()
public abstract ClassDefinition[] getClassDefinitions()
public abstract java.lang.String[] getDeletedAttributes()
public abstract java.lang.String[] getModifiedAttributes()
public abstract ObjectEntry getObjectEntry()
public abstract long getRevision()
public abstract NSObject clone(ObjectEntry newIdentity) throws NamespaceException
newIdentity - The ObjectEntry whos identity is assumed.NamespaceException - NamespaceException.OBJECTTYPE_NOT_VALID is
thrown if the newIdentity's type is different from this.public java.lang.Object clone()
clone in class java.lang.Objectpublic abstract void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
listener - The listener to be added.public abstract void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
listener - The listener to be removed.public abstract void clearAddedAttribute(java.lang.String attrName)
attrName - The valued attribute to be removed from the add list.public abstract void clearDeletedAttribute(java.lang.String attrName)
attrName - The valued attribute to be removed from the delete list.public abstract void clearModifiedAttribute(java.lang.String attrName)
attrName - The valued attribute to be removed from the modify list.public abstract boolean isAttributeMandatory(java.lang.String attrName)
attrName - Name of the attribute to look for.public abstract boolean isAttributeOptional(java.lang.String attrName)
attrName - Name of the attribute to look for.public abstract boolean isNamedBy(java.lang.String attrName)
attrName - Name of the attribute to look for.public abstract boolean addAuxiliaryClassDefinition(ClassDefinition classDef, ObjectAttribute[] attrs) throws NamespaceException
classDef - The class definition to add.attrs - The attributes to add.NamespaceException - The association of the aux class failed.public abstract boolean deleteAuxiliaryClassDefinition(ClassDefinition classDef) throws NamespaceException
classDef - The class definition to add.NamespaceException - The deletion of the auxiliary class failed.protected abstract void setClassDefinition()
public abstract boolean isAddPossible(ObjectAttribute attr, boolean isForAuxClass) throws NamespaceException
NamespaceException
API Documentation Copyright © 1998-2004 Novell, Inc. All rights reserved.
NDS is a registered trademark of Novell, Inc. in the United States and other countries.
Generated ${TODAY} ${TSTAMP}.