com.waveset.object
Class ObjectGroup

java.lang.Object
  extended bycom.waveset.object.PersistentObject
      extended bycom.waveset.object.ObjectGroup
All Implemented Interfaces:
java.lang.Comparable, javax.naming.Referenceable, XmlObject

public class ObjectGroup
extends PersistentObject

An ObjectGroup is a collection of PersistentObjects. ObjectGroups can be nested to form a hierarchy.

Lighthouse predefines two instances of ObjectGroup:


Nested Class Summary
static class ObjectGroup.ResourceContainerInfo
          Used for values of the _resetCheck field.
 
Nested classes inherited from class com.waveset.object.PersistentObject
PersistentObject.Comparator, PersistentObject.InitialInstance
 
Field Summary
protected  java.util.List _auditPolicies
          A list of ObjectRefs to audit policies.
protected  java.lang.String[] _path
          cache the path if we have generated it before (it is used a lot in the gui).
protected  java.lang.String[] _pathAsIDs
          cache the IDs of the path members If an object group changes, the cache will get reloaded so this should not go stale.
protected  ObjectGroup.ResourceContainerInfo _resourceContainerInfo
          if this object group is a "virtual" object group which represent a directory resource container, this object will describe the resource and the id of the container.
protected  boolean _useOrgDisplayNames
           
protected  ObjectRef _userFormRef
          the ObjectRef of a user form that will be used for creating/editing users by all principals (admins, users, etc.) that are members of this object group
protected  java.lang.String _userMembersRuleCacheTimeout
          If resource objects queries are to be cached, this option specifies the number of milliseconds before the cache times out.
protected  ObjectRef _userMembersRuleRef
          object ref to a rule that evaluates to a list of 0 or more users that are members of this object group.
protected  ObjectRef _viewUserFormRef
          the ObjectRef of a user form that will be used by a view only admin that are members of this object group
static ObjectGroup All
           
static java.lang.String code_id
           
static ObjectGroup Top
           
 
Fields inherited from class com.waveset.object.PersistentObject
_trace, trace
 
Constructor Summary
ObjectGroup()
           
ObjectGroup(org.w3c.dom.Element e)
           
ObjectGroup(ObjectGroup src)
          Clone the object, cloning the object refs to remove any resolved refs that might not belong to the new object's cache.
ObjectGroup(java.lang.String name)
           
 
Method Summary
 void addApprover(ObjectRef ref)
          Add one approver to our approver list.
 void addApprover(WSUser admin)
          Add one approver to our approver list.
 void addAuditPolicyRef(ObjectRef ref)
           
 void addPolicyRef(ObjectRef ref)
           
protected  void addSubclassElements(java.lang.StringBuffer b)
          Each concrete subclass may append to the buffer an XML representation of any fields it adds to PersistentObject (if those field values must persist).
 void clearApprovers()
          Clear the approvers list.
 PersistentObject cloneObject()
          Clones an object.
 boolean dupOrgInParent()
           
 java.util.ArrayList getApproverRefs()
          Get the list of approver object references for this role.
 WSUser[] getApprovers()
          Get an array of resolved approver objects for this group.
protected  WSAttribute getAttributeValues(java.lang.String attrName)
           
 java.util.List getAuditPolicies()
           
 java.util.List getAuditPolicyRefs()
           
 void getChildObjectGroupIds(java.util.List childogidlist)
          Similar to getChildObjectGroupNames, but builds a list of ids instead.
 void getChildObjectGroupNames(java.util.List childognamelist)
          For this ObjectGroup, the method will find all child object groups (e.g.
 void getChildObjectGroupPathNames(java.util.List childogpathnamelist)
          Similar to getChildObjectGroupNames, but builds a list of pathnames instead.
 void getChildObjectGroups(java.util.List childoglist)
          Similar to getChildObjectGroupNames, but builds a list of objects instead.
 void getDirectChildObjectGroupIds(java.util.List childogidlist)
          Similar to getChildObjectGroupIds, but returns only child object group ids whose parent is this object group
 java.lang.String getDisplayableName()
          Override this to return the path which is what we really want to display for orgs.
static PersistentObject.InitialInstance[] getInitialInstances()
          Returns the set of initial instances that should be created for this object type when a repository is created.
static java.util.List getMemberObjectGroupDisplayNames(ObjectSource objSrc, PersistentObject po)
          Return a list of displayNames of the member object groups of the PersistentObject parameter.
static java.util.List getMemberObjectGroupNames(ObjectSource objSrc, PersistentObject po)
          Return a List of String where the Strings are names of the member object groups of the PersistentObject parameter.
static java.util.List getMemberObjectGroupPaths(ObjectSource objSrc, PersistentObject po)
          Return a list of paths of the member object groups of the PersistentObject parameter.
 java.lang.String getName()
          Return the name of this object.
static java.lang.String getObjectGroupHandle(ObjectSource objSrc, ObjectRef ref)
          Return the org path or displayName for the given object reference.
static java.util.List getObjectGroupHandles(ObjectSource objSrc, java.util.List objectRefs)
          Return a list of org paths or displayNames for the given list of object references.
static ObjectRef getObjectGroupRef(ObjectSource objSrc, java.lang.String orgHandle)
          Takes an orgHandles (either name, path, or displayname) and returns a formal object reference.
static java.util.List getObjectGroupRefs(ObjectSource objSrc, java.util.List orgList)
          Takes a list of orgHandles (either names, paths, or displaynames) and returns a list of formal object references.
static java.lang.String getOrganizationPath(ObjectSource objSrc, ObjectGroup group)
           
static java.util.List getOrganizationPathList(ObjectSource objSrc, ObjectGroup group, boolean returnIDs)
          Build a list of names or IDs from the given organization back to the top containing the names of each intermediate object groups.
 java.lang.String[] getPath()
           
 java.lang.String[] getPath(boolean returnIDs)
           
 java.lang.String[] getPathAsIDs()
           
 java.lang.String getPathString()
          Return the organization path as a string of path elements seperated by colons.
 java.util.List getPolicies()
           
 java.util.List getPolicyRefs()
           
 java.util.ArrayList getReferences()
          Return the list of references within this object.
 ObjectGroup.ResourceContainerInfo getResourceContainerInfo()
           
static java.util.List getTopControlledObjectGroups(LighthouseContext lc, Subject subject)
          Returns the set of 0 or more object groups controlled by the given Subject, each of which has no object group parent that is also controlled by the principal.
 Type getType()
          Return the type of this object.
 Configuration getUserForm()
           
 java.lang.String getUserFormId()
           
 ObjectRef getUserFormRef()
           
 java.lang.String getUserMembersRuleCacheTimeout()
          If resource objects queries are to be cached, this option specifies the number of milliseconds before the cache times out.
 ObjectRef getUserMembersRuleRef()
           
 Configuration getViewUserForm()
           
 java.lang.String getViewUserFormId()
           
 ObjectRef getViewUserFormRef()
           
 boolean isJunction()
           
 boolean isVirtual()
           
 java.util.List listQueryableAttributes()
           
protected  void listQueryableSummaryAttributes(java.util.List attrs)
           
 java.util.List listSummaryAttributes()
          Returns the complete list of defined attributes that this type of persistent object exposes as summary attributes (regardless of whether this particular object has a value for each).
static void normalizeObjectGroup(ObjectSource objSrc, ObjectGroup org)
          Update the path (from the top of the organization hierarchy) for the specified object group.
protected  void parseSubclassElements(org.w3c.dom.Element e)
          Each concrete subclass should parse from the XML buffer any persisted subclass-specific elements (generally, the same ones that it writes into the buffer).
 void prepareForSerialization()
          Overrides PersistentObject to ensure that our "pathname" within the organization hierarchy is up-to-date before this object is serialized (i.e., stored persistently).
 void setAuditPolicyRef(ObjectRef ref)
           
 void setAuditPolicyRefs(java.util.List policies)
           
 void setCache(ObjectCache c)
          Overridden from PersistentObject to invalidate our path string cache - if the cache is changing, the path to top may change.
 void setPath(java.lang.String[] path)
           
 void setPathAsIDs(java.lang.String[] IDPath)
           
 void setPolicyRef(ObjectRef ref)
           
 void setPolicyRefs(java.util.List policies)
           
 void setResourceContainerInfo(ObjectGroup.ResourceContainerInfo resourceContainerInfo)
           
 void setUseOrgDisplayNames(boolean val)
           
 void setUserForm(Configuration userForm)
           
 void setUserFormRef(ObjectRef userFormRef)
           
 void setUserMembersRuleCacheTimeout(java.lang.String userMembersRuleCacheTimeout)
           
 void setUserMembersRuleRef(ObjectRef userMembersRuleRef)
           
 void setViewUserForm(Configuration viewUserForm)
           
 void setViewUserFormRef(ObjectRef viewUserFormRef)
           
static java.lang.String stripPath(java.lang.String path)
          Given an organization name in "path" form, remove the path prefix.
static boolean useOrgDisplayNames(ObjectSource objSrc)
           
 void visit(Visitor v)
          Visitor interface.
 
Methods inherited from class com.waveset.object.PersistentObject
addCommonElements, addEndTag, addMemberObjectGroup, addMemberObjectGroup, addPersistentAttributes, addStartTag, addSubclassAttributes, addSummaryAttributes, addXmlHeader, attributesMatch, attributesMatch, attributesMatch, checkReference, checkReferences, clearId, cloneAs, compareTo, create, create, create, create, createLastModItem, createLastModItem, createLastModItemList, directObjectGroupMember, dump, dumpFile, equals, fakeId, getAttribute, getAttributeValues, getAuthReferences, getAuthType, getBasicAttributes, getBasicAttributes, getBasicAttributes, getCache, getCounterValue, getCreateDate, getCreator, getDisplayName, getElementName, getEncryptedValues, getId, getIdOrName, getLastMod, getLastModDate, getLastModifier, getLastModItemId, getLockInfo, getMemberObjectGroupRefs, getMemberObjectGroupRefsUpTo, getMemberObjectGroups, getNameOrId, getProperties, getProperty, getPropertyAsString, getPropertyList, getQueryableAttributes, getReference, getRuleDrivenMemberObjectGroupRefs, getRuleDrivenMemberObjectGroupRefsUpTo, getRuleDrivenMemberObjectGroups, getSubtype, getSummaryAttributes, getSummaryString, hasEncryptedData, hashCode, identityEquals, isAlias, isHidden, isId, isProtected, isProtectedFromDelete, isReferencedIn, listOperationalAttributes, listQueryableReferenceAttributes, objectGroupMember, objectGroupMemberRef, parseCommonElement, parseCommonElements, parsePersistentAttributes, parseSubclassAttributes, parseXml, parseXml, prepareToSerialize, println, reEncrypt, reEncryptSubclassAttributes, removeMemberObjectGroup, removeProperty, resolve, resolve, resolve, resolveArray, resolveArrayByFetching, resolveObjectReference, resolveObjectReferences, resolveReference, resolveSummaryAttributes, resolveSummaryAttributes, ruleDrivenObjectGroupMemberRef, setAuthType, setAuthType, setCreateDate, setCreator, setDisplayName, setDisplayName, setHidden, setIsAlias, setLastMod, setLastMod, setLastModDate, setLastModifier, setMemberObjectGroupRef, setMemberObjectGroupRefs, setMemberObjectGroups, setName, setProperties, setProperty, setPropertyList, setProtected, setProtectedFromDelete, setRuleDrivenMembersCache, setSubtype, setTrace, toString, toXml, toXml, toXml, toXmlFile
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

code_id

public static final java.lang.String code_id
See Also:
Constant Field Values

Top

public static ObjectGroup Top

All

public static ObjectGroup All

_userFormRef

protected ObjectRef _userFormRef
the ObjectRef of a user form that will be used for creating/editing users by all principals (admins, users, etc.) that are members of this object group


_viewUserFormRef

protected ObjectRef _viewUserFormRef
the ObjectRef of a user form that will be used by a view only admin that are members of this object group


_path

protected java.lang.String[] _path
cache the path if we have generated it before (it is used a lot in the gui). If an object group changes, the cache will get reloaded so this should not go stale.


_pathAsIDs

protected java.lang.String[] _pathAsIDs
cache the IDs of the path members If an object group changes, the cache will get reloaded so this should not go stale.


_useOrgDisplayNames

protected boolean _useOrgDisplayNames

_resourceContainerInfo

protected ObjectGroup.ResourceContainerInfo _resourceContainerInfo
if this object group is a "virtual" object group which represent a directory resource container, this object will describe the resource and the id of the container.


_userMembersRuleRef

protected ObjectRef _userMembersRuleRef
object ref to a rule that evaluates to a list of 0 or more users that are members of this object group. The rule is passed the user view of the currently authenticated subject. The rule should return a list of zero or more resource account ids format as follows: ":". This rule is used when querying the members of a given object group and checking access to user objects.


_userMembersRuleCacheTimeout

protected java.lang.String _userMembersRuleCacheTimeout
If resource objects queries are to be cached, this option specifies the number of milliseconds before the cache times out. When the cache times out, the objects will automatically be retrieved from the resource the next time they are requested


_auditPolicies

protected java.util.List _auditPolicies
A list of ObjectRefs to audit policies.

Constructor Detail

ObjectGroup

public ObjectGroup()

ObjectGroup

public ObjectGroup(org.w3c.dom.Element e)
            throws WavesetException

ObjectGroup

public ObjectGroup(java.lang.String name)

ObjectGroup

public ObjectGroup(ObjectGroup src)
            throws WavesetException
Clone the object, cloning the object refs to remove any resolved refs that might not belong to the new object's cache. This is a "shallow" copy, modelled on the ObjectRef copy.

Method Detail

getName

public java.lang.String getName()
Description copied from class: PersistentObject
Return the name of this object.

Overrides:
getName in class PersistentObject

getDisplayableName

public java.lang.String getDisplayableName()
Override this to return the path which is what we really want to display for orgs.

Overrides:
getDisplayableName in class PersistentObject

setUseOrgDisplayNames

public void setUseOrgDisplayNames(boolean val)

getInitialInstances

public static final PersistentObject.InitialInstance[] getInitialInstances()
Description copied from class: PersistentObject
Returns the set of initial instances that should be created for this object type when a repository is created.

ServerRepository initialization will call this method on the Java class associated with each Type to get a list of the items it should "seed" into the repository.

Each initial instance contains a PersistentObject to be added, as well as boolean methods that describe any special handling.


getType

public Type getType()
Description copied from class: PersistentObject
Return the type of this object. This must be implemented by each subclass.

Specified by:
getType in class PersistentObject

getReferences

public java.util.ArrayList getReferences()
Return the list of references within this object.

Overrides:
getReferences in class PersistentObject

setCache

public void setCache(ObjectCache c)
Overridden from PersistentObject to invalidate our path string cache - if the cache is changing, the path to top may change.

Overrides:
setCache in class PersistentObject
Parameters:
c - - an object cache

setPath

public void setPath(java.lang.String[] path)

setPathAsIDs

public void setPathAsIDs(java.lang.String[] IDPath)

getPathAsIDs

public java.lang.String[] getPathAsIDs()

getPath

public java.lang.String[] getPath()
                           throws WavesetException
Throws:
WavesetException

getPath

public java.lang.String[] getPath(boolean returnIDs)
                           throws WavesetException
Throws:
WavesetException

getPathString

public java.lang.String getPathString()
Return the organization path as a string of path elements seperated by colons. This is the format typically used in the GUI.

TODO: Support an option to filter out organization names that the user is not authorized to see. This probably can't be done at this level? - jsl


stripPath

public static java.lang.String stripPath(java.lang.String path)
Given an organization name in "path" form, remove the path prefix.


getChildObjectGroupNames

public void getChildObjectGroupNames(java.util.List childognamelist)
                              throws WavesetException
For this ObjectGroup, the method will find all child object groups (e.g. ObjectGroups that are direct or indirect members of this object group), get the name for each, add it to the list, and return the list. If there are no child object groups, null will be returned.

Inputs: - childognamelist - non-null list to be populated with child object group names

Throws:
WavesetException

getChildObjectGroupPathNames

public void getChildObjectGroupPathNames(java.util.List childogpathnamelist)
                                  throws WavesetException
Similar to getChildObjectGroupNames, but builds a list of pathnames instead.

Throws:
WavesetException

getChildObjectGroupIds

public void getChildObjectGroupIds(java.util.List childogidlist)
                            throws WavesetException
Similar to getChildObjectGroupNames, but builds a list of ids instead.

Throws:
WavesetException

getChildObjectGroups

public void getChildObjectGroups(java.util.List childoglist)
                          throws WavesetException
Similar to getChildObjectGroupNames, but builds a list of objects instead.

Throws:
WavesetException

getDirectChildObjectGroupIds

public void getDirectChildObjectGroupIds(java.util.List childogidlist)
                                  throws WavesetException
Similar to getChildObjectGroupIds, but returns only child object group ids whose parent is this object group

Throws:
WavesetException

prepareForSerialization

public void prepareForSerialization()
                             throws WavesetException
Overrides PersistentObject to ensure that our "pathname" within the organization hierarchy is up-to-date before this object is serialized (i.e., stored persistently). Otherwise, PersistentObject.getQueryableAttributes() may expose an incorrect value for CONTAINED_BY_OBJECT_GROUP.

Since we must resolve object references in order to do this, we have to do it in this method (while we have an ObjectCache).

Overrides:
prepareForSerialization in class PersistentObject
Throws:
WavesetException

listQueryableAttributes

public java.util.List listQueryableAttributes()
Overrides:
listQueryableAttributes in class PersistentObject
Returns:
the complete list of defined attributes that this type of persistent object exposes as queryable (regardless of whether this particular object has a value for each).

Any subclass of PersistentObject that overrides this method should first invoke super.listQueryableAttributes() to ensure that the subclass includes queryable attributes that are common to all PersistentObjects.


listSummaryAttributes

public java.util.List listSummaryAttributes()
Description copied from class: PersistentObject
Returns the complete list of defined attributes that this type of persistent object exposes as summary attributes (regardless of whether this particular object has a value for each).

Any subclass of PersistentObject that overrides this method should first invoke super.listSummaryAttributes() to ensure that the subclass includes summary attributes that are common to all PersistentObjects.

Any subclass that overrides this implementation must also consider the length of the summary string that will be generated from these attributes.

Overrides:
listSummaryAttributes in class PersistentObject
Returns:
the complete list of defined attributes that this this type persistent object exposes as summary attributes (regardless of whether this particular object has a value for each).

Any subclass of PersistentObject that overrides this method should first invoke super.getSummaryAttributes() to ensure that the subclass includes summary attributes that are common to all PersistentObjects.

See Also:
Constants.MAX_SUMMARY_STRING_LENGTH, PersistentObject.getSummaryString()

listQueryableSummaryAttributes

protected void listQueryableSummaryAttributes(java.util.List attrs)

getAttributeValues

protected WSAttribute getAttributeValues(java.lang.String attrName)
Overrides:
getAttributeValues in class PersistentObject
Parameters:
attrName - - the name of the attribute for which to return values.
Returns:
a WSAttribute that represents the value (or values) that this object contains for the specified attribute.


getApproverRefs

public java.util.ArrayList getApproverRefs()
Get the list of approver object references for this role.

These are references to Administrators that are considered approvers for provisioning requests using this group.


getApprovers

public WSUser[] getApprovers()
                      throws WavesetException
Get an array of resolved approver objects for this group.

Throws:
WavesetException

clearApprovers

public void clearApprovers()
Clear the approvers list.


addApprover

public void addApprover(ObjectRef ref)
Add one approver to our approver list.

These should be administrators with APPROVAL rights. Can't check that here, it will have to be done as part of the Checkin validator. The GUI currently tries to prevent selection of bad values.


addApprover

public void addApprover(WSUser admin)
Add one approver to our approver list.

These should be administrators with APPROVAL rights. Can't check that here, it will have to be done as part of the Checkin validator. The GUI currently tries to prevent selection of bad values.

If you want to specify a completely new list, call clearApprovers first.

See Also:
clearApprovers()

visit

public void visit(Visitor v)
           throws WavesetException
Visitor interface.

Overrides:
visit in class PersistentObject
Throws:
WavesetException

getViewUserFormRef

public ObjectRef getViewUserFormRef()

getViewUserForm

public Configuration getViewUserForm()
                              throws WavesetException
Throws:
WavesetException

getViewUserFormId

public java.lang.String getViewUserFormId()

setViewUserFormRef

public void setViewUserFormRef(ObjectRef viewUserFormRef)

setViewUserForm

public void setViewUserForm(Configuration viewUserForm)

getUserFormRef

public ObjectRef getUserFormRef()

getUserForm

public Configuration getUserForm()
                          throws WavesetException
Throws:
WavesetException

getUserFormId

public java.lang.String getUserFormId()

setUserFormRef

public void setUserFormRef(ObjectRef userFormRef)

setUserForm

public void setUserForm(Configuration userForm)

dupOrgInParent

public boolean dupOrgInParent()
                       throws WavesetException
Throws:
WavesetException

setPolicyRefs

public void setPolicyRefs(java.util.List policies)

setPolicyRef

public void setPolicyRef(ObjectRef ref)

addPolicyRef

public void addPolicyRef(ObjectRef ref)

getPolicyRefs

public java.util.List getPolicyRefs()

getPolicies

public java.util.List getPolicies()
                           throws WavesetException
Returns:
a List of Policy objects, resolved from getPolicyRefs
Throws:
WavesetException

getResourceContainerInfo

public ObjectGroup.ResourceContainerInfo getResourceContainerInfo()

setResourceContainerInfo

public void setResourceContainerInfo(ObjectGroup.ResourceContainerInfo resourceContainerInfo)

isVirtual

public boolean isVirtual()

isJunction

public boolean isJunction()

getUserMembersRuleRef

public ObjectRef getUserMembersRuleRef()

setUserMembersRuleRef

public void setUserMembersRuleRef(ObjectRef userMembersRuleRef)

setAuditPolicyRefs

public void setAuditPolicyRefs(java.util.List policies)

setAuditPolicyRef

public void setAuditPolicyRef(ObjectRef ref)

addAuditPolicyRef

public void addAuditPolicyRef(ObjectRef ref)

getAuditPolicyRefs

public java.util.List getAuditPolicyRefs()

getAuditPolicies

public java.util.List getAuditPolicies()
                                throws WavesetException
Returns:
a List of Audit Policy objects, resolved from getPolicyRefs
Throws:
WavesetException

getUserMembersRuleCacheTimeout

public java.lang.String getUserMembersRuleCacheTimeout()
If resource objects queries are to be cached, this option specifies the number of milliseconds before the cache times out. When the cache times out, the objects will automatically be retrieved from the resource the next time they are requested


setUserMembersRuleCacheTimeout

public void setUserMembersRuleCacheTimeout(java.lang.String userMembersRuleCacheTimeout)

addSubclassElements

protected void addSubclassElements(java.lang.StringBuffer b)
Description copied from class: PersistentObject
Each concrete subclass may append to the buffer an XML representation of any fields it adds to PersistentObject (if those field values must persist). PersistentObject's default implementation is a no-op.

NOTE: Any subclass that overrides this method must similarly override parseSubclassElements() so that the subclass elements are restored.

Overrides:
addSubclassElements in class PersistentObject
See Also:


parseSubclassElements

protected void parseSubclassElements(org.w3c.dom.Element e)
                              throws WavesetException
Description copied from class: PersistentObject
Each concrete subclass should parse from the XML buffer any persisted subclass-specific elements (generally, the same ones that it writes into the buffer).

Overrides:
parseSubclassElements in class PersistentObject
Throws:
WavesetException
See Also:

PersistentObject's default implementation is a no-op.

, PersistentObject.parseXml(Element)

cloneObject

public PersistentObject cloneObject()
                             throws WavesetException
Description copied from class: PersistentObject
Clones an object.

We don't overload the java.lang.Object.clone method because it can't throw any exceptions, and there is the potential for deserialization errors here (though I suppose we could throw an unchecked exceptions).

The clone is done using the XML serialization that all PersistentObjects must support. It would probably be more efficient to implement java.lang.Serializable, but that's another serialization format that would have to be debugged. Since we have to support XML transforms anyway, just use that.

Overrides:
cloneObject in class PersistentObject
Returns:
an exact duplicate (a clone) of this object.

Overridden for speed because object groups are moved between caches a lot.

Throws:
WavesetException - if there were problems duplicating the object

useOrgDisplayNames

public static boolean useOrgDisplayNames(ObjectSource objSrc)
                                  throws WavesetException
Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Returns:
true if SystemConfiguration specifies that object groups should use display names. Otherwise, if object groups should use organization paths, return false.

Throws:
WavesetException

normalizeObjectGroup

public static void normalizeObjectGroup(ObjectSource objSrc,
                                        ObjectGroup org)
                                 throws WavesetException
Update the path (from the top of the organization hierarchy) for the specified object group.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getOrganizationPathList

public static java.util.List getOrganizationPathList(ObjectSource objSrc,
                                                     ObjectGroup group,
                                                     boolean returnIDs)
                                              throws WavesetException
Build a list of names or IDs from the given organization back to the top containing the names of each intermediate object groups.

Assumes that object groups can have only a single parent object group and therefore every object group will have a single unique fully qualified path from Top or All.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getOrganizationPath

public static java.lang.String getOrganizationPath(ObjectSource objSrc,
                                                   ObjectGroup group)
                                            throws WavesetException
Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getTopControlledObjectGroups

public static java.util.List getTopControlledObjectGroups(LighthouseContext lc,
                                                          Subject subject)
                                                   throws WavesetException
Returns the set of 0 or more object groups controlled by the given Subject, each of which has no object group parent that is also controlled by the principal.

Throws:
WavesetException

getMemberObjectGroupNames

public static java.util.List getMemberObjectGroupNames(ObjectSource objSrc,
                                                       PersistentObject po)
                                                throws WavesetException
Return a List of String where the Strings are names of the member object groups of the PersistentObject parameter. The names are scoped to the current administrator/user.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getMemberObjectGroupDisplayNames

public static java.util.List getMemberObjectGroupDisplayNames(ObjectSource objSrc,
                                                              PersistentObject po)
                                                       throws WavesetException
Return a list of displayNames of the member object groups of the PersistentObject parameter. The names are scoped to the current administrator/user.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getMemberObjectGroupPaths

public static java.util.List getMemberObjectGroupPaths(ObjectSource objSrc,
                                                       PersistentObject po)
                                                throws WavesetException
Return a list of paths of the member object groups of the PersistentObject parameter. The paths are scoped to the current administrator/user.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getObjectGroupHandle

public static java.lang.String getObjectGroupHandle(ObjectSource objSrc,
                                                    ObjectRef ref)
                                             throws WavesetException
Return the org path or displayName for the given object reference. If the configuration object for #useOrgDisplayNames is true, the handle will be an org displayName, otherwise it will be an org path.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getObjectGroupHandles

public static java.util.List getObjectGroupHandles(ObjectSource objSrc,
                                                   java.util.List objectRefs)
                                            throws WavesetException
Return a list of org paths or displayNames for the given list of object references. If the configuration object for #useOrgDisplayNames is true, the handles will be org displayNames, otherwise they will be org paths.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
Throws:
WavesetException

getObjectGroupRef

public static ObjectRef getObjectGroupRef(ObjectSource objSrc,
                                          java.lang.String orgHandle)
                                   throws WavesetException
Takes an orgHandles (either name, path, or displayname) and returns a formal object reference.

Parameters:
objSrc - - an ObjectSource such as a ViewMaster or LighthouseContext.
orgHandle - - an object group identifier (e.g., name, path or displayName).
Returns:
an object reference to the object group.
Throws:
WavesetException

getObjectGroupRefs

public static java.util.List getObjectGroupRefs(ObjectSource objSrc,
                                                java.util.List orgList)
                                         throws WavesetException
Takes a list of orgHandles (either names, paths, or displaynames) and returns a list of formal object references.

Parameters:
objSrc - - an ObjectSource used to resolve object references.
orgList - - a list of org handles (names, paths or displayNames).
Returns:
a list of object references to organizations.
Throws:
WavesetException