com.sun.enterprise.deployment
Class MethodPermission

java.lang.Object
  extended by java.util.Observable
      extended by com.sun.enterprise.deployment.DynamicAttributesDescriptor
          extended by com.sun.enterprise.deployment.Descriptor
              extended by com.sun.enterprise.deployment.MethodPermission
All Implemented Interfaces:
java.io.Serializable

public class MethodPermission
extends Descriptor

Represents a method permission. A method permission can be associated to a role, be unchecked or excluded.

Version:
Author:
Jerome Dochez
See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.sun.enterprise.deployment.Descriptor
DESCRIPTION_CHANGED, DESCRIPTOR_CHANGED, docType, LARGE_ICON_CHANGED, NAME_CHANGED, SMALL_ICON_CHANGED
 
Constructor Summary
MethodPermission(Role role)
          construct a new MethodPermission based on a security role
 
Method Summary
 boolean equals(java.lang.Object other)
           
static MethodPermission getExcludedMethodPermission()
           
 Role getRole()
           
static MethodPermission getUncheckedMethodPermission()
           
 int hashCode()
           
 boolean isExcluded()
           
 boolean isRoleBased()
           
 boolean isUnchecked()
           
 void print(java.lang.StringBuffer toStringBuffer)
          A String representation of this object.
 
Methods inherited from class com.sun.enterprise.deployment.Descriptor
addDeploymentExtension, addPrefixMapping, createUniqueFilenameAmongst, createUniqueNameAmongst, createUniqueNameAmongstNamedDescriptors, fillDocType, getDeploymentExtensions, getDescription, getDisplayName, getDocType, getLargeIconUri, getLocalizedDescription, getLocalizedDescriptions, getLocalizedDisplayName, getLocalizedDisplayNames, getLocalizedLargeIconUri, getLocalizedLargeIconUris, getLocalizedSmallIconUri, getLocalizedSmallIconUris, getName, getPrefixMapping, getSmallIconUri, isBoundsChecking, setBoundsChecking, setDescription, setDisplayName, setLargeIconUri, setLocalizedDescription, setLocalizedDisplayName, setLocalizedLargeIconUri, setLocalizedSmallIconUri, setName, setSmallIconUri, visit
 
Methods inherited from class com.sun.enterprise.deployment.DynamicAttributesDescriptor
addExtraAttribute, getExtraAttribute, getExtraAttributes, removeExtraAttribute, toString
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MethodPermission

public MethodPermission(Role role)
construct a new MethodPermission based on a security role

Parameters:
role - the security role associated to the method permission
Method Detail

getUncheckedMethodPermission

public static MethodPermission getUncheckedMethodPermission()
Returns:
an unchecked method permission. Methods associated with such a method permission can be invoked by anyone

getExcludedMethodPermission

public static MethodPermission getExcludedMethodPermission()
Returns:
an ecluded method permission. Methods associated with such a method permission cannot be invoked by anyone.

isRoleBased

public boolean isRoleBased()
Returns:
true if the method permission is based on a security role

isUnchecked

public boolean isUnchecked()
Returns:
true if the method permission is unchecked

isExcluded

public boolean isExcluded()
Returns:
true if the method permission is excluded

getRole

public Role getRole()
Returns:
the security role associated with this method permission when applicable (role based method permission)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

print

public void print(java.lang.StringBuffer toStringBuffer)
Description copied from class: Descriptor
A String representation of this object.

Overrides:
print in class Descriptor


Copyright © 2012 GlassFish Community. All Rights Reserved.