com.waveset.object
Class AdminRole

java.lang.Object
  extended bycom.waveset.object.PersistentObject
      extended bycom.waveset.object.Principal
          extended bycom.waveset.object.AdminRole
All Implemented Interfaces:
java.lang.Comparable, javax.naming.Referenceable, java.io.Serializable, XmlObject

public class AdminRole
extends Principal

An Admin Role enables the definition of unique combinations of scope and capabilities which can then be assigned to a User to more granularly control what the user is allowed to do and on which objects. One or more Admin Roles can be assigned to a single User and one or more Users can be assigned the same Admin Role.

See Also:
Serialized Form

Nested Class Summary
static class AdminRole.AssignToUsers
          This is an object containing the information that will determine the set of users this admin role should be auto-assigned to.
static class AdminRole.ControlledObjects
          This is an object containing the type, list, and rules that will determine the set of objects, of the specified type, that are in the scope of the user assigned this admin role.
static class AdminRole.ControlledObjectSubGroup
          A class that contains a reference to an object group and one or more member object refs that should either be included or excluded from access.
 
Nested classes inherited from class com.waveset.object.PersistentObject
PersistentObject.Comparator, PersistentObject.InitialInstance
 
Field Summary
static java.lang.String code_id
           
static java.lang.String EXCLUDE
           
static java.lang.String INCLUDE
           
static java.lang.String USER_ADMIN_ROLE
          The name of a special admin role that is implicitly assigned to all users.
 
Fields inherited from class com.waveset.object.Principal
_adminGroupRefs, _adminGroups, _adminGroupsRuleRef, _adminRoleRefs, _controlledObjectGroupRefs, _controlledObjectGroups, _controlledObjectGroupsRuleRef, _permissions, _userFormRef, _viewUserFormRef, LAST_LOGIN_LOCALE_PROP, LOCALE_PROP
 
Fields inherited from class com.waveset.object.PersistentObject
_trace, trace
 
Constructor Summary
AdminRole()
           
AdminRole(org.w3c.dom.Element e)
           
AdminRole(java.lang.String name)
           
 
Method Summary
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).
 ObjectRef getAdminGroupsOnObjectRuleRef()
           
 java.util.List getAssignerRefs()
           
 AdminRole.AssignToUsers getAssignToUsers()
           
protected  WSAttribute getAttributeValues(java.lang.String attrName)
           
 AdminRole.ControlledObjects getControlledObjects()
           
 java.util.Map getControlledObjectSubGroupObjectGroups(java.lang.String command)
           
 java.util.List getControlledObjectSubGroups()
           
 java.util.ArrayList getReferences()
          Return the list of references within this object.
 Type getType()
          Return the type of this object.
 boolean includesExcludesTypeForOrg(Type type, ObjectRef ogref)
          Test to see if this AdminRole includes or excludes any objects of the specified Type in the specified object group (org)
 java.util.List listQueryableAttributes()
           
 java.util.List listQueryableReferenceAttributes()
           
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 setAdminGroupsOnObjectRuleRef(ObjectRef adminGroupsOnObjectRuleRef)
           
 void setAssignerRefs(java.util.List assignerRefs)
           
 void setAssignToUsers(AdminRole.AssignToUsers assignToUsers)
           
 void setControlledObjects(AdminRole.ControlledObjects controlledObjects)
           
 void setControlledObjectSubGroups(java.util.List controlledObjectSubGroups)
           
 void visit(Visitor v)
          Visitor interface.
 
Methods inherited from class com.waveset.object.Principal
addAdminGroup, addAdminGroupRef, addCommonPrincipalElements, addControlledObjectGroup, addPermission, clearAdminGroups, getAdminGroupRefs, getAdminGroups, getAdminGroupsRuleRef, getAdminRoleRefs, getAdminRoles, getControlledObjectGroupRefs, getControlledObjectGroups, getControlledObjectGroupsRuleRef, getEncryptedValues, getPermissions, getUserForm, getUserFormId, getUserFormRef, getViewUserForm, getViewUserFormId, getViewUserFormRef, hasCapabilities, listSummaryAttributes, parseCommonPrincipalElements, parsePermissions, removeAdminGroup, removeControlledObjectGroup, removePermission, setAdminGroupRefs, setAdminGroups, setAdminGroupsRuleRef, setAdminRoleRefs, setAdminRoles, setControlledObjectGroupRefs, setControlledObjectGroups, setControlledObjectGroupsRuleRef, setPermissions, setUserForm, setUserFormRef, setViewUserForm, setViewUserFormRef
 
Methods inherited from class com.waveset.object.PersistentObject
addCommonElements, addEndTag, addMemberObjectGroup, addMemberObjectGroup, addPersistentAttributes, addStartTag, addSubclassAttributes, addSummaryAttributes, addXmlHeader, attributesMatch, attributesMatch, attributesMatch, checkReference, checkReferences, clearId, cloneAs, cloneObject, compareTo, create, create, create, create, createLastModItem, createLastModItem, createLastModItemList, directObjectGroupMember, dump, dumpFile, equals, fakeId, getAttribute, getAttributeValues, getAuthReferences, getAuthType, getBasicAttributes, getBasicAttributes, getBasicAttributes, getCache, getCounterValue, getCreateDate, getCreator, getDisplayableName, getDisplayName, getElementName, getId, getIdOrName, getInitialInstances, getLastMod, getLastModDate, getLastModifier, getLastModItemId, getLockInfo, getMemberObjectGroupRefs, getMemberObjectGroupRefsUpTo, getMemberObjectGroups, getName, getNameOrId, getProperties, getProperty, getPropertyAsString, getPropertyList, getQueryableAttributes, getReference, getRuleDrivenMemberObjectGroupRefs, getRuleDrivenMemberObjectGroupRefsUpTo, getRuleDrivenMemberObjectGroups, getSubtype, getSummaryAttributes, getSummaryString, hasEncryptedData, hashCode, identityEquals, isAlias, isHidden, isId, isProtected, isProtectedFromDelete, isReferencedIn, listOperationalAttributes, objectGroupMember, objectGroupMemberRef, parseCommonElement, parseCommonElements, parsePersistentAttributes, parseSubclassAttributes, parseXml, parseXml, prepareForSerialization, prepareToSerialize, println, reEncrypt, reEncryptSubclassAttributes, removeMemberObjectGroup, removeProperty, resolve, resolve, resolve, resolveArray, resolveArrayByFetching, resolveObjectReference, resolveObjectReferences, resolveReference, resolveSummaryAttributes, resolveSummaryAttributes, ruleDrivenObjectGroupMemberRef, setAuthType, setAuthType, setCache, 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

INCLUDE

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

EXCLUDE

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

USER_ADMIN_ROLE

public static final java.lang.String USER_ADMIN_ROLE
The name of a special admin role that is implicitly assigned to all users. This is used to expose objects through the end-user GUI to users that don't ordinarilly have any capabilities or control any groups.

See Also:
Constant Field Values
Constructor Detail

AdminRole

public AdminRole()

AdminRole

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

AdminRole

public AdminRole(java.lang.String name)
Method Detail

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 Principal

getControlledObjectSubGroups

public java.util.List getControlledObjectSubGroups()

setControlledObjectSubGroups

public void setControlledObjectSubGroups(java.util.List controlledObjectSubGroups)

includesExcludesTypeForOrg

public boolean includesExcludesTypeForOrg(Type type,
                                          ObjectRef ogref)
Test to see if this AdminRole includes or excludes any objects of the specified Type in the specified object group (org)


getControlledObjectSubGroupObjectGroups

public java.util.Map getControlledObjectSubGroupObjectGroups(java.lang.String command)
                                                      throws WavesetException
Throws:
WavesetException

getControlledObjects

public AdminRole.ControlledObjects getControlledObjects()

setControlledObjects

public void setControlledObjects(AdminRole.ControlledObjects controlledObjects)

getAdminGroupsOnObjectRuleRef

public ObjectRef getAdminGroupsOnObjectRuleRef()

setAdminGroupsOnObjectRuleRef

public void setAdminGroupsOnObjectRuleRef(ObjectRef adminGroupsOnObjectRuleRef)

getAssignToUsers

public AdminRole.AssignToUsers getAssignToUsers()

setAssignToUsers

public void setAssignToUsers(AdminRole.AssignToUsers assignToUsers)

getAssignerRefs

public java.util.List getAssignerRefs()

setAssignerRefs

public void setAssignerRefs(java.util.List assignerRefs)

listQueryableAttributes

public java.util.List listQueryableAttributes()
Overrides:
listQueryableAttributes in class Principal
Returns:
the complete list of defined attributes that this type of persistent object exposes as queryable attributes (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 list of queryable attribute for PersistentObjects are included in the subclasses list.


listQueryableReferenceAttributes

public java.util.List listQueryableReferenceAttributes()
Overrides:
listQueryableReferenceAttributes in class Principal
Returns:
the complete list of defined attributes that this type of persistent object exposes as queryable attributes and for which each value is a reference to another persistent object.

Any subclasses of Principal that overrides this method must first invoke super.listQueryableReferenceAttributes() to ensure that the following attributes are returned as queryable reference attributes for all Principals

  • MemberAdminGroups
  • ControlledObjectGroups
  • AdminRoles

getAttributeValues

protected WSAttribute getAttributeValues(java.lang.String attrName)
Overrides:
getAttributeValues in class Principal
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.


visit

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

Overrides:
visit in class PersistentObject
Throws:
WavesetException

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)