|
EASP API 6.1.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
This interface is for interacting with objects that are persistent (i.e. that are stored in SSC's LDAP directory). These objects have identity, names, descriptions, and attributes. The identity is system generated. The name is the value of the LDAP RDN of the object, and is fixed for the lifetime of the object. The name is always unique amongst the object's siblings (i.e. those within the same container; for example, all the subscriptions for a single subscriber will have different names). All Persistent objects have a display name which is initially the same as the name of the object, but which can be changed.
The enterprise server caches persistent objects on a
per-manager-session basis. A manager's session lasts for the period between a call to ServiceProvider.bind and a subsequent call to ServiceProvider.unbind or ServiceProvider.bind (see ServiceProvider for details on binding).
If the directory is modified during a Manager's session, ServiceProvider.clearCache or ServiceProvider.bind must be called again to see the new versions of the objects.
Persistent objects implement a change notification system. Interested objects can register as listeners to listen for changes to Persistent objects. Since persistent objects are cached on a per-manager-session basis, if the same persistent object is accessed more than once within a manager session, multiple references to the same object will be handed out by this API, and not references to multiple cached copies of the persistent data. Thus, if a listener is added to a persistent object, it will recieve change notifications for any update to the object provided that the update originates in the same manager session. Updates notifications will not be sent if the persisent object is changed by another manager session, or if it is changed in the directory by any other external systems.
| Method Summary | |
void |
addListener(PersistentChangeListener l)
Adds a listener to this object. |
void |
delListener(PersistentChangeListener l)
Removes a listener from this object. |
Object[] |
getAttribute(String name)
Returns the named attribute from this object's LDAP entry. |
String |
getDisplayName()
This method returns a cached copy of the value of getAttribute("displayname")[0], or, if no such
attribute exists, the value of the LDAP RDN for this Persistent object's LDAP entry. |
String |
getId()
Returns the unique system-generated identifier of this object. |
String |
getName()
Returns the value of the LDAP RDN for this object, which is unique amongst its sibling objects. |
void |
setAttribute(String name,
Object[] values)
Overwrites the values of the named attribute in this object's LDAP entry. |
void |
setAttribute(String name,
String[] values)
Deprecated. use setAttribute(String name, Object values[]) instead |
void |
setDisplayName(String name)
Sets the display name of this object. |
| Method Detail |
public String getId()
public String getName()
public String getDisplayName()
getAttribute("displayname")[0], or, if no such
attribute exists, the value of the LDAP RDN for this Persistent object's LDAP entry.
public void setDisplayName(String name)
throws CommunicationException,
AccessControlException
setAttribute method for
the "displayname" attribute of this object.
AccessControlException - Thrown if the current manager doesn't have the privilige of setting the display name.
CommunicationException - Thrown if there is a problem communicating with the directory.
public Object[] getAttribute(String name)
throws CommunicationException,
AccessControlException
name - The name of the attribute in the LDAP schema for this object.
CommunicationException - Thrown if there is a problem communicating with the directory.
AccessControlException - Thrown if the current manager does not have permission to access
the named attribute.
public void setAttribute(String name,
Object[] values)
throws CommunicationException,
AccessControlException,
ViolateSchemaException
name - The name of the attribute in the LDAP schema for this object.values - The new values for the attribute.
CommunicationException - Thrown if there is a problem communicating with the directory.
AccessControlException - Thrown if the current manager does not have write access for the named attribute.
ViolateSchemaException - Thrown if this object's LDAP schema does not allow the given attribute or if multiple values are given for a single-valued attribute.
public void setAttribute(String name,
String[] values)
throws CommunicationException,
AccessControlException,
ViolateSchemaException
name - The name of the attribute in the LDAP schema for this object.values - The new values for the attribute.
CommunicationException - Thrown if there is a problem communicating with the directory.
AccessControlException - Thrown if the current manager does not have write access for the named attribute.
ViolateSchemaException - Thrown if this object's LDAP schema does not allow the given attribute or if multiple values are given for a single-valued attribute.public void addListener(PersistentChangeListener l)
public void delListener(PersistentChangeListener l)
|
EASP API 6.1.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||