oracle.ifs.beans
Class DirectoryObject


java.lang.Object

  |

  +--oracle.ifs.beans.LibraryObject

        |

        +--oracle.ifs.beans.TieLibraryObject

              |

              +--oracle.ifs.beans.PublicObject

                    |

                    +--oracle.ifs.beans.TiePublicObject

                          |

                          +--oracle.ifs.beans.DirectoryObject

All Implemented Interfaces:
DirectoryObjectInterface, IfsEventHandler, LibraryObjectInterface, PublicObjectInterface, Traceable
Direct Known Subclasses:
TieDirectoryObject

public class DirectoryObject
extends TiePublicObject
implements DirectoryObjectInterface

A DirectoryObject represents an iFS user or group of users.

This class is essentially abstract. The two major subclasses of this class are DirectoryUser and DirectoryGroup. Many operations require some user or group entity, and therefore use DirectoryObject to represent this. For example, security grant and revoke operations can use either a user or group as the grantee, and therefore take a DirectoryObject argument.

DirectoryObject is a subclass of PublicObject; hence, DirectoryObject can have associated AccessControlLists to manage security on the DirectoryObjects. Typically, DirectoryUser objects are accessible to all users (that is, their ACL has Discover granted to the "World" group).


Field Summary
static java.lang.String CLASS_NAME
          Class name for this class.
 
Fields inherited from class oracle.ifs.beans.PublicObject
ACL_ATTRIBUTE, ADMINISTRATIONGROUP_ATTRIBUTE, CREATEDATE_ATTRIBUTE, CREATOR_ATTRIBUTE, DELETOR_ATTRIBUTE, DESCRIPTION_ATTRIBUTE, EXPIRATIONDATE_ATTRIBUTE, FAMILY_ATTRIBUTE, FLAGS_ATTRIBUTE, LASTMODIFIER_ATTRIBUTE, LASTMODIFYDATE_ATTRIBUTE, LOCKEDFORSESSION_ATTRIBUTE, LOCKSTATE_ATTRIBUTE, LOCKSTATE_HARDLOCK, LOCKSTATE_SESSIONLOCK, LOCKSTATE_SOFTLOCK, LOCKSTATE_UNLOCK, LOCKSTATE_USERLOCK, NAME_ATTRIBUTE, OWNER_ATTRIBUTE, POLICYBUNDLE_ATTRIBUTE, PROPERTYBUNDLE_ATTRIBUTE, RESOLVEDPUBLICOBJECT_ATTRIBUTE, SECURINGPUBLICOBJECT_ATTRIBUTE
 
Method Summary
 DirectoryGroup[] getAllAncestors()
          Gets all ancestors to this DirectoryObject.
 DirectoryGroup getAllAncestors(int index)
          Gets all ancestors to this DirectoryObject at the specified index.
 DirectoryObject[] getAllMembers()
          Gets all members belonging to this DirectoryObject.
 DirectoryObject getAllMembers(int index)
          Gets a specific memeber at the specified index in array of DirectoryObject.
 DirectoryUser[] getAllUserMembers()
          Gets all DirectoryUser members belonging to this DirectoryObject.
 DirectoryUser getAllUserMembers(int index)
          Gets a specific DirectoryUser Member at the specified index in array of DirectoryObject.
 DirectoryGroup[] getDirectAncestors()
          Gets the direct ancestors to this DirectoryObject.
 DirectoryGroup getDirectAncestors(int index)
          Gets the direct ancestors to this DirectoryObject at the specified index.
 DirectoryObject[] getDirectMembers()
          Gets the direct members belonging to this DirectoryObject.
 DirectoryObject getDirectMembers(int index)
          Gets the specific direct member at the specified index in array of DirectoryObject.
 void handleEvent(IfsEvent event)
          Handles the specified event.
 void resetAllAncestors()
          Clears locally cached list of all ancestors.
 void resetDirectAncestors()
          Clears locally cached list of direct ancestors.
 
Methods inherited from class oracle.ifs.beans.PublicObject
addCategory, addRelationship, checkEffectiveAccess, checkEffectiveAccess, copy, getAcl, getAllFolderPaths, getAllFolderPaths, getAnyFolderPath, getAnyFolderPath, getCategories, getCategories, getCreateDate, getCreator, getDefaultAccessLevel, getDescription, getEffectiveAccessLevel, getEffectiveAccessLevel, getExpirationDate, getFamily, getFlags, getFolderReferencesSortSpecification, getLastModifier, getLastModifyDate, getLeftwardRelationshipObjects, getLeftwardRelationshipObjects, getLeftwardRelationships, getLeftwardRelationships, getLockedState, getLockState, getLockStateLabel, getOwner, getPolicyBundle, getPropertyBundle, getResolvedPublicObject, getRightwardRelationshipObjects, getRightwardRelationshipObjects, getRightwardRelationships, getRightwardRelationships, getSecuringPublicObject, grantAccess, hasNameAttribute, isLocked, isLockedForSession, isLockedForSessionByCurrentSession, isVersionable, isVersioned, lock, putPolicy, putProperty, putProperty, removeAllPolicies, removeAllProperties, removePolicy, removePolicy, removeProperty, removeRelationship, revokeAccess, revokeAllAccess, setAcl, setDescription, setExpirationDate, setFlags, setFolderReferencesSortSpecification, setOwner, setPolicyBundle, setPropertyBundle, setSecuringPublicObject, toLockStateLabel, toLockStateLabel, toLockStateLabel, unlock
 
Methods inherited from class oracle.ifs.beans.LibraryObject
equals, free, free, getAttribute, getAttributeByUpperCaseName, getAttributes, getAttributesByUpperCaseNames, getClassId, getClassObject, getDefinition, getId, getLabel, getName, getSession, invokeServerMethod, isInstanceOf, isTraced, lookupInstanceLabel, postEvent, postEvent, renderAsReader, renderAsStream, setAttribute, setAttribute, setAttributes, setAttributes, setName, toString, trace, update
 
Methods inherited from interface oracle.ifs.common.LibraryObjectInterface
getId
 
Methods inherited from interface oracle.ifs.common.Traceable
getTraceLogger, isTraced, trace
 

Field Detail


CLASS_NAME


public static final java.lang.String CLASS_NAME
Class name for this class.

Useful for methods that take a class name argument.

Method Detail

getAllMembers


public DirectoryObject[] getAllMembers()
                                throws IfsException
Gets all members belonging to this DirectoryObject.

For DirectoryGroup, this method is overridden to produce the full set of member DirectoryObjects that are members (directly or indirectly) of that DirectoryGroup.

For DirectoryUser, the array only contains the target object.

Returns:
array of member DirectoryObjects
Throws:
IfsException - if operation fails.

getAllMembers


public DirectoryObject getAllMembers(int index)
                              throws IfsException
Gets a specific memeber at the specified index in array of DirectoryObject.

For the DirectoryObject class, the only valid index is zero(0), which will return this object.

Parameters:
index - index into the array of DirectoryObjects
Returns:
the requested DirectoryGroup
Throws:
IfsException - if operation fails.

getAllUserMembers


public DirectoryUser[] getAllUserMembers()
                                  throws IfsException
Gets all DirectoryUser members belonging to this DirectoryObject.

This list is the full set of member DirectoryUsers that are members (directly or indirectly) of this DirectoryGroup.

Returns:
array of member DirectoryUsers
Throws:
IfsException - if operation fails.

getAllUserMembers


public DirectoryUser getAllUserMembers(int index)
                                throws IfsException
Gets a specific DirectoryUser Member at the specified index in array of DirectoryObject.
Parameters:
index - index into the array of DirectoryGroups
Returns:
the requested DirectoryObject
Throws:
IfsException - if operation fails.

getDirectMembers


public DirectoryObject[] getDirectMembers()
                                   throws IfsException
Gets the direct members belonging to this DirectoryObject.

For DirectoryGroup objects, this method is overridden to return the set of direct members of that DirectoryGroup.

For DirectoryUser obejects, a null array is returned.

Returns:
array of direct member DirectoryObjects
Throws:
IfsException - if operation fails.

getDirectMembers


public DirectoryObject getDirectMembers(int index)
                                 throws IfsException
Gets the specific direct member at the specified index in array of DirectoryObject.
Parameters:
index - index into the array of DirectoryObjects
Returns:
the requested DirectoryObject
Throws:
IfsException - if operation fails.

getDirectAncestors


public DirectoryGroup[] getDirectAncestors()
                                    throws IfsException
Gets the direct ancestors to this DirectoryObject.
Returns:
array of DirectoryGroup
Throws:
IfsException - if operation fails.

getDirectAncestors


public DirectoryGroup getDirectAncestors(int index)
                                  throws IfsException
Gets the direct ancestors to this DirectoryObject at the specified index.
Parameters:
index - index into the array of DirectoryGroup
Returns:
the requested DirectoryGroup
Throws:
IfsException - if operation fails.

resetDirectAncestors


public void resetDirectAncestors()
                          throws IfsException
Clears locally cached list of direct ancestors.

This must be called to force a new array of getDirectAncestors to be fetched from the server.

Throws:
IfsException - if operation fails.

getAllAncestors


public DirectoryGroup[] getAllAncestors()
                                 throws IfsException
Gets all ancestors to this DirectoryObject.
Returns:
array of DirectoryGroup
Throws:
IfsException - if operation fails.

getAllAncestors


public DirectoryGroup getAllAncestors(int index)
                               throws IfsException
Gets all ancestors to this DirectoryObject at the specified index.
Parameters:
index - index into the array of DirectoryGroup
Returns:
the requested DirectoryGroup
Throws:
IfsException - if operation fails.

resetAllAncestors


public void resetAllAncestors()
                       throws IfsException
Clears locally cached list of all ancestors.

This must be called to force a new array of getAllAncestors to be fetched from the server.

Throws:
IfsException - if the operation fails

handleEvent


public void handleEvent(IfsEvent event)
                 throws IfsException
Handles the specified event.

This override resets the directAncestor and allAncestor cache held by this instance.

Overrides:
handleEvent in class PublicObject
Parameters:
event - the specific event to be handled
Throws:
IfsException - if the operation fails