org.springframework.security.acls.domain
Class AbstractPermission
java.lang.Object
org.springframework.security.acls.domain.AbstractPermission
- All Implemented Interfaces:
- Serializable, Permission
- Direct Known Subclasses:
- BasePermission, CumulativePermission
public abstract class AbstractPermission
- extends Object
- implements Permission
Provides an abstract superclass for Permission implementations.
- Since:
- 2.0.3
- Author:
- Ben Alex
- See Also:
AbstractRegisteredPermission,
Serialized Form
|
Field Summary |
protected char |
code
|
protected int |
mask
|
code
protected char code
mask
protected int mask
AbstractPermission
protected AbstractPermission(int mask,
char code)
equals
public final boolean equals(Object arg0)
- Overrides:
equals in class Object
getMask
public final int getMask()
- Description copied from interface:
Permission
- Returns the bits that represents the permission.
- Specified by:
getMask in interface Permission
- Returns:
- the bits that represent the permission
getPattern
public String getPattern()
- Description copied from interface:
Permission
- Returns a 32-character long bit pattern
String representing this permission.
Implementations are free to format the pattern as they see fit, although under no circumstances may
Permission.RESERVED_OFF or Permission.RESERVED_ON be used within the pattern. An exemption is in the case of
Permission.RESERVED_OFF which is used to denote a bit that is off (clear).
Implementations may also elect to use Permission.RESERVED_ON internally for computation purposes,
although this method may not return any String containing Permission.RESERVED_ON.
The returned String must be 32 characters in length.
This method is only used for user interface and logging purposes. It is not used in any permission
calculations. Therefore, duplication of characters within the output is permitted.
- Specified by:
getPattern in interface Permission
- Returns:
- a 32-character bit pattern
toString
public final String toString()
- Overrides:
toString in class Object
hashCode
public final int hashCode()
- Overrides:
hashCode in class Object
Copyright © 2004-2010 SpringSource, Inc. All Rights Reserved.