Package com.spotfire.server.jaas
Class JAASUserPrincipal
java.lang.Object
com.spotfire.server.jaas.JAASUserPrincipal
- All Implemented Interfaces:
Serializable,Principal
This class can be used as a base class for
Principal implementations representing users.- Since:
- 3.0
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionJAASUserPrincipal(String username) Creates a newJAASUserPrincipalinstance with the given username. -
Method Summary
Modifier and TypeMethodDescriptionbooleanCompares the specified object with thisJAASUserPrincipalinstance.getName()This method returns the name of the principal.inthashCode()Returns the hash code value for the principal.toString()The method returns aStringrepresentation of this principal.
-
Constructor Details
-
JAASUserPrincipal
Creates a newJAASUserPrincipalinstance with the given username.- Parameters:
username- the username- Since:
- 3.0
-
-
Method Details
-
getName
This method returns the name of the principal. -
hashCode
public int hashCode()Returns the hash code value for the principal. The returned hash code is the same as the hash code for theStringcontaining the name of the principal. -
equals
Compares the specified object with thisJAASUserPrincipalinstance. The method returnstrueif the two objects are of the same concrete subclass ofJAASUserPrincipaland they both have the same name. Otherwise, the method returnsfalse. -
toString
The method returns aStringrepresentation of this principal.
-