org.jboss.security
Class SimplePrincipal
java.lang.Object
org.jboss.security.SimplePrincipal
- All Implemented Interfaces:
- java.security.Principal, java.io.Serializable
- Direct Known Subclasses:
- CallerIdentity (src) , NestableGroup (src) , NestablePrincipal (src) , SimpleGroup (src) , SRPPrincipal (src)
- public class SimplePrincipal
- extends java.lang.Object
- implements java.security.Principal, java.io.Serializable
A simple String based implementation of Principal. Typically a
SimplePrincipal is created given a userID which is used as the Principal
name.
- See Also:
- Serialized Form
|
Method Summary |
boolean |
equals(java.lang.Object another)
Compare this SimplePrincipal's name against another Principal |
java.lang.String |
getName()
|
int |
hashCode()
|
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
SimplePrincipal
public SimplePrincipal(java.lang.String name)
equals
public boolean equals(java.lang.Object another)
- Compare this SimplePrincipal's name against another Principal
- Specified by:
equals in interface java.security.Principal
- Returns:
- true if name equals another.getName();
hashCode
public int hashCode()
- Specified by:
hashCode in interface java.security.Principal
toString
public java.lang.String toString()
- Specified by:
toString in interface java.security.Principal
getName
public java.lang.String getName()
- Specified by:
getName in interface java.security.Principal