public class PolicyStatement
extends java.lang.Object
grant Principal com.foo.UserPrincipal "fred"
{
permission java.io.FilePermission "file:D:/sample/foo.txt", "read,write";
permission com.foo.CustomPermission "mySpreadSheet", "open,close";
};
The above PolicyStatement represents granting of two permission to a Principal "fred"| Constructor and Description |
|---|
PolicyStatement(java.security.Principal grantee, java.security.Permission permission)
Internal: Applications should not use this method. Constructs a PolicyStatement for a given Principal and permission.
|
| Modifier and Type | Method and Description |
|---|---|
java.security.Permission |
getPermission()
Internal: Applications should not use this method. Accessor for the Permissions assocated with this grantee
|
java.security.Principal |
getPrincipal()
Internal: Applications should not use this method. Accessor for the Principal associated with this PolicyStatement
|
public PolicyStatement(java.security.Principal grantee,
java.security.Permission permission)
grantee - the Principal associated with this PolicyStatement.permission - the Permission associated with this PolicyStatement.public java.security.Principal getPrincipal()
public java.security.Permission getPermission()