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 booleanequals(Object obj)Two principals are equal, if their names are.StringgetName()inthashCode()StringtoString()
-
-
-
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:
equalsin interfacePrincipal- Overrides:
equalsin classObject- See Also:
Object.equals(Object)
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfacePrincipal- Overrides:
hashCodein classObject- Returns:
- the hash code of the principals name.
- See Also:
Object.hashCode()
-
-