|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectatg.security.PersonaAdapter
public class PersonaAdapter
An adapter class useful for creating implementations of the Persona interface.
| Field Summary | |
|---|---|
static java.lang.String |
CLASS_VERSION
|
| Constructor Summary | |
|---|---|
PersonaAdapter(java.lang.String pName,
UserAuthority pAuthority)
Creates a new persona with a given name and user authority. |
|
| Method Summary | |
|---|---|
void |
addSubPersona(Persona pNewPersona)
Adds a new sub-persona. |
boolean |
equals(java.lang.Object object)
Returns true if this persona is equivalent to another. |
java.util.Collection |
getAccessRights()
Does actual lookup of sub-persona information. |
java.lang.Object |
getAttribute(java.lang.String pAttributeName)
Retrieves the value of a named attribute of the persona's account. |
java.lang.String |
getName()
Returns a machine-readable name of the access right, useful for persisting the object. |
Persona[] |
getSubPersonae()
Returns a list of sub-personae that compose this persona. |
UserAuthority |
getUserAuthority()
Returns the authority that manages this persona. |
int |
hashCode()
Returns the hash code of the persona's name. |
boolean |
hasPersona(Persona pPersona)
Returns true if this persona matches or encompasses the indicated persona. |
boolean |
hasRole(java.lang.String pRoleName)
Returns true if this persona is or has a sub-persona with the given name. |
boolean |
isReadOnly()
Returns true if this Persona has been marked as read-only. |
static void |
main(java.lang.String[] args)
|
void |
removeSubPersona(Persona pOldPersona)
Removes a sub-persona. |
void |
setAttribute(java.lang.String pName,
java.lang.Object pValue)
Adds a new attribute to the attribute map. |
void |
setAttributes(java.util.Map mNewAttributes)
Sets the entire collection of attributes. |
void |
setReadOnly(boolean b)
If set to true, this Persona becomes immutable. |
void |
setSubPersonae(Persona[] pNewPersonae)
Changes the list of sub-personae that compose this persona. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static java.lang.String CLASS_VERSION
| Constructor Detail |
|---|
public PersonaAdapter(java.lang.String pName,
UserAuthority pAuthority)
| Method Detail |
|---|
public boolean isReadOnly()
public void setReadOnly(boolean b)
public void setAttribute(java.lang.String pName,
java.lang.Object pValue)
public void setAttributes(java.util.Map mNewAttributes)
public java.lang.String toString()
toString in interface java.security.PrincipaltoString in class java.lang.Objectpublic int hashCode()
hashCode in interface java.security.PrincipalhashCode in class java.lang.Objectpublic boolean equals(java.lang.Object object)
equals in interface Personaequals in interface java.security.Principalequals in class java.lang.Objectpublic java.lang.String getName()
getName in interface PersonagetName in interface java.security.Principalpublic UserAuthority getUserAuthority()
getUserAuthority in interface Personapublic boolean hasPersona(Persona pPersona)
hasPersona in interface Personapublic Persona[] getSubPersonae()
getSubPersonae in interface Persona
public void setSubPersonae(Persona[] pNewPersonae)
throws InvalidPersonaException
setSubPersonae in interface PersonaInvalidPersonaException
public void addSubPersona(Persona pNewPersona)
throws InvalidPersonaException
addSubPersona in interface PersonaInvalidPersonaException
public void removeSubPersona(Persona pOldPersona)
throws InvalidPersonaException
removeSubPersona in interface PersonaInvalidPersonaExceptionpublic java.lang.Object getAttribute(java.lang.String pAttributeName)
getAttribute in interface PersonaSecurityDomain.createResource(java.lang.Object, java.lang.Object, atg.security.AccessControlEntry[])public boolean hasRole(java.lang.String pRoleName)
hasRole in interface Personapublic java.util.Collection getAccessRights()
getAccessRights in interface Personapublic static void main(java.lang.String[] args)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||