info.magnolia.jaas.principal
Class AbstractPrincipalList

java.lang.Object
  extended by info.magnolia.jaas.principal.AbstractPrincipalList
All Implemented Interfaces:
PrincipalList, java.io.Serializable, java.security.Principal
Direct Known Subclasses:
GroupListImpl, RoleListImpl

public abstract class AbstractPrincipalList
extends java.lang.Object
implements PrincipalList

Implementation of the PrincipalList providing most common functionality.

Version:
$Revision: $ ($Author: $)
Author:
gjoseph
See Also:
Serialized Form

Constructor Summary
protected AbstractPrincipalList()
           
 
Method Summary
 void add(java.lang.String name)
          Adds a name to the list.
 java.util.Collection getList()
          Gets list of roles as string.
 java.lang.String getName()
          Gets name given to this principal.
 boolean has(java.lang.String name)
          Checks if the role name exist in this list.
 void setName(java.lang.String name)
          Sets principal name.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.security.Principal
equals, hashCode
 

Constructor Detail

AbstractPrincipalList

protected AbstractPrincipalList()
Method Detail

getName

public java.lang.String getName()
Gets name given to this principal.

Specified by:
getName in interface PrincipalList
Specified by:
getName in interface java.security.Principal
Returns:
name

setName

public void setName(java.lang.String name)
Sets principal name.

Specified by:
setName in interface PrincipalList
Parameters:
name -

add

public void add(java.lang.String name)
Adds a name to the list.

Specified by:
add in interface PrincipalList
Parameters:
name -

getList

public java.util.Collection getList()
Gets list of roles as string.

Specified by:
getList in interface PrincipalList
Returns:
roles

has

public boolean has(java.lang.String name)
Checks if the role name exist in this list.

Specified by:
has in interface PrincipalList
Parameters:
name -

toString

public java.lang.String toString()
Specified by:
toString in interface java.security.Principal
Overrides:
toString in class java.lang.Object
See Also:
Object.toString()


Copyright © 2003-2011 Magnolia International Ltd.. All Rights Reserved.