Class PrincipalImpl
- java.lang.Object
-
- org.apache.jackrabbit.core.security.principal.PrincipalImpl
-
- All Implemented Interfaces:
Serializable
,Principal
,JackrabbitPrincipal
- Direct Known Subclasses:
UnknownPrincipal
public class PrincipalImpl extends Object implements JackrabbitPrincipal, Serializable
Base class for implementations ofJackrabbitPrincipal
.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PrincipalImpl(String name)
Creates a new principal with the given name.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
Two principals are equal, if their names are.String
getName()
int
hashCode()
String
toString()
-
-
-
Constructor Detail
-
PrincipalImpl
public PrincipalImpl(String name)
Creates a new principal with the given name.- Parameters:
name
- the name of this principal
-
-
Method Detail
-
equals
public boolean equals(Object obj)
Two principals are equal, if their names are.- Specified by:
equals
in interfacePrincipal
- Overrides:
equals
in classObject
- See Also:
Object.equals(Object)
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacePrincipal
- Overrides:
hashCode
in classObject
- Returns:
- the hash code of the principals name.
- See Also:
Object.hashCode()
-
-