org.apache.tomcat.util.aaa
Class SimplePrincipal
java.lang.Object
|
+--org.apache.tomcat.util.aaa.SimplePrincipal
- All Implemented Interfaces:
- java.security.Principal
- Direct Known Subclasses:
- JDBCRealm.JdbcPrincipal, SimpleRealm.SimpleRealmPrincipal
- public class SimplePrincipal
- extends java.lang.Object
- implements java.security.Principal
Method Summary |
boolean |
equals(java.lang.Object another)
Returns true if the specified Object represents the
same principal (i.e. |
java.lang.String |
getName()
Returns the principal's name. |
java.lang.String |
toString()
Returns the principal's name. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.security.Principal |
hashCode |
SimplePrincipal
public SimplePrincipal(java.lang.String name)
equals
public boolean equals(java.lang.Object another)
- Returns true if the specified Object represents the
same principal (i.e. a Principal with the same name)
- Specified by:
equals
in interface java.security.Principal
- Overrides:
equals
in class java.lang.Object
- Parameters:
another
- Another Principal instance- Returns:
- true if another is a Principal with the same name
getName
public java.lang.String getName()
- Returns the principal's name.
- Specified by:
getName
in interface java.security.Principal
- Returns:
- The principal's name
toString
public java.lang.String toString()
- Returns the principal's name.
- Specified by:
toString
in interface java.security.Principal
- Overrides:
toString
in class java.lang.Object
- Returns:
- The principal's name
Copyright ? 2001 Apache Software Foundation. All Rights Reserved.