org.jboss.metadata.javaee.spec
Class SecurityRoleMetaData

java.lang.Object
  extended by org.jboss.metadata.javaee.support.IdMetaDataImpl
      extended by org.jboss.metadata.javaee.support.NamedMetaData
          extended by org.jboss.metadata.javaee.support.NamedMetaDataWithDescriptions
              extended by org.jboss.metadata.javaee.spec.SecurityRoleMetaData
All Implemented Interfaces:
Serializable, Cloneable, IdMetaData, MappableMetaData, MergeableMappedMetaData<SecurityRoleMetaData>, MergeableMetaData<SecurityRoleMetaData>

public class SecurityRoleMetaData
extends NamedMetaDataWithDescriptions
implements MergeableMappedMetaData<SecurityRoleMetaData>

SecurityRoleMetaData.

Version:
$Revision: 1.1 $
Author:
Adrian Brock, Scott.Stark@jboss.org
See Also:
Serialized Form

Constructor Summary
SecurityRoleMetaData()
          Create a new SecurityRoleMetaData.
 
Method Summary
 Set<String> getPrincipals()
          Get the principals.
 String getRoleName()
          Get the roleName.
 boolean hasPrincipal(String userName)
          Whether this roles has the principal
 SecurityRoleMetaData merge(SecurityRoleMetaData original)
          Merge some metadata
 void merge(SecurityRoleMetaData override, SecurityRoleMetaData original)
           
 void setPrincipals(Set<String> principals)
          Set the principals.
 void setRoleName(String roleName)
          Set the roleName.
 
Methods inherited from class org.jboss.metadata.javaee.support.NamedMetaDataWithDescriptions
getDescriptions, setDescriptions
 
Methods inherited from class org.jboss.metadata.javaee.support.NamedMetaData
equals, getKey, getName, hashCode, merge, setName, toString
 
Methods inherited from class org.jboss.metadata.javaee.support.IdMetaDataImpl
clone, getId, merge, merge, setId
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jboss.metadata.javaee.support.MappableMetaData
getKey
 

Constructor Detail

SecurityRoleMetaData

public SecurityRoleMetaData()
Create a new SecurityRoleMetaData.

Method Detail

getRoleName

public String getRoleName()
Get the roleName.

Returns:
the roleName.

setRoleName

public void setRoleName(String roleName)
Set the roleName.

Parameters:
roleName - the roleName.
Throws:
IllegalArgumentException - for a null roleName

getPrincipals

public Set<String> getPrincipals()
Get the principals.

Returns:
the principals.

setPrincipals

public void setPrincipals(Set<String> principals)
Set the principals.

Parameters:
principals - the principals.
Throws:
IllegalArgumentException - for a null principals

hasPrincipal

public boolean hasPrincipal(String userName)
Whether this roles has the principal

Parameters:
userName - the principal
Returns:
true when it has the principal
Throws:
IllegalArgumentException - for a null principal

merge

public SecurityRoleMetaData merge(SecurityRoleMetaData original)
Description copied from interface: MergeableMetaData
Merge some metadata

Specified by:
merge in interface MergeableMetaData<SecurityRoleMetaData>
Parameters:
original - the original
Returns:
the merged metadata

merge

public void merge(SecurityRoleMetaData override,
                  SecurityRoleMetaData original)


Copyright © 2009 JBoss Inc.. All Rights Reserved.