org.apache.jetspeed.om.security
Class UserNamePrincipal
java.lang.Object
org.apache.jetspeed.om.security.UserNamePrincipal
- All Implemented Interfaces:
- java.security.Principal
- public class UserNamePrincipal
- extends java.lang.Object
- implements java.security.Principal
A Principal based on the user name.
- Version:
- $Id: UserNamePrincipal.java,v 1.4 2004/02/23 03:14:12 jford Exp $
- Author:
- David Sean Taylor
Method Summary |
boolean |
equals(java.lang.Object another)
Compares this principal to the specified object. |
java.lang.String |
getName()
Returns the name of this principal. |
java.lang.String |
toString()
Returns a string representation of this principal. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.security.Principal |
hashCode |
UserNamePrincipal
public UserNamePrincipal(java.lang.String userName)
equals
public boolean equals(java.lang.Object another)
- Compares this principal to the specified object. Returns true
if the object passed in matches the principal represented by
the implementation of this interface.
- Specified by:
equals
in interface java.security.Principal
- Parameters:
another
- principal to compare with.
- Returns:
- true if the principal passed in is the same as that
encapsulated by this principal, and false otherwise.
toString
public java.lang.String toString()
- Returns a string representation of this principal.
- Specified by:
toString
in interface java.security.Principal
- Returns:
- a string representation of this principal.
getName
public java.lang.String getName()
- Returns the name of this principal.
- Specified by:
getName
in interface java.security.Principal
- Returns:
- the name of this principal.
Copyright © 2000-2005 Apache Software Foundation. All Rights Reserved.