|
Oracle® Coherence Java API Reference v3.5 E14977-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectjava.security.Permission
com.tangosol.net.ClusterPermission
public final class ClusterPermission
This class represents access to a clustered resource such as a Service or NamedCache. A ClusterPermission consists of a target name and a set of actions valid for that target.
Target name is a string containing a list of one or more comma-separated target attributes. The valid target attributes are:
CacheService (e.g. InvocationService).
A target name string consisting of a single "*" indicates all clustered
resources.
The actions to be granted are passed to the constructor in a string
containing a list of one or more comma-separated keywords. The possible
keywords are: "create", "destroy", "join", "manage", "all".
An action string "all" indicates a combination of all valid actions.
Note: the actions string is converted to lowercase before processing.
| Field Summary | |
|---|---|
static int |
ALL
All actions. |
static int |
CREATE
Create action. |
static int |
DESTROY
Create action. |
static int |
JOIN
Join action. |
static int |
NONE
No actions. |
| Constructor Summary | |
|---|---|
ClusterPermission(java.lang.String sTarget,
java.lang.String sAction)
Construct a ClusterPermission object. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object obj)
Checks two Permission objects for equality. |
static java.lang.String |
formatAction(int nAction)
Format the action string. |
java.lang.String |
getActions()
Return the actions as a String in a canonical form. |
java.lang.String |
getServiceName()
Return the service name for this permission object or null if the permission applies to any service. |
int |
hashCode()
Return the hash code value for this ClusterPermission object. |
boolean |
implies(java.security.Permission permission)
Check if the specified permission's actions are "implied by" this object's actions. |
static void |
main(java.lang.String[] asArg)
Unit test allows to compare the specified permissions. |
protected void |
parseAction(java.lang.String sAction)
Parse the action string and set the action flag. |
protected void |
parseTarget(java.lang.String sTarget)
Parse the target string. |
| Methods inherited from class java.security.Permission |
|---|
checkGuard, getName, newPermissionCollection, toString |
| Field Detail |
|---|
public static final int CREATE
public static final int DESTROY
public static final int JOIN
public static final int ALL
public static final int NONE
| Constructor Detail |
|---|
public ClusterPermission(java.lang.String sTarget,
java.lang.String sAction)
sTarget - the clustered resource name; must be specifiedsAction - the action(s) name; must be specified| Method Detail |
|---|
public java.lang.String getActions()
getActions in class java.security.Permissionpublic boolean implies(java.security.Permission permission)
implies in class java.security.Permissionpermission - the permission to check against
public boolean equals(java.lang.Object obj)
equals in class java.security.Permissionobj - the object we are testing for equality with this object
public int hashCode()
hashCode in class java.security.Permissionpublic java.lang.String getServiceName()
protected void parseTarget(java.lang.String sTarget)
sTarget - the target stringprotected void parseAction(java.lang.String sAction)
sAction - the action stringpublic static java.lang.String formatAction(int nAction)
nAction - the action mask
public static void main(java.lang.String[] asArg)
java com.tangosol.net.ClusterPermission
|
Oracle® Coherence Java API Reference v3.5 E14977-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||