public final class PropertyPermission extends java.security.BasicPermission
System.getProperty.System.setProperty.Permission,
BasicPermission,
SecurityManager,
Serialized Form| Constructor and Description |
|---|
PropertyPermission(java.lang.String name,
java.lang.String actions)
Constructs a PropertyPermission with the specified property.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj)
Check to see whether this object is the same as another
PropertyPermission object; this is true if it has the same name and
actions.
|
java.lang.String |
getActions()
Returns the action string.
|
int |
hashCode()
Returns the hash code for this permission.
|
boolean |
implies(java.security.Permission p)
Check if this permission implies p.
|
java.security.PermissionCollection |
newPermissionCollection()
Returns a permission collection suitable to take
PropertyPermission objects.
|
public PropertyPermission(java.lang.String name, java.lang.String actions)
name - the name of the propertyactions - the action stringjava.lang.NullPointerException - if name is nulljava.lang.IllegalArgumentException - if name string contains an
illegal wildcard or actions string contains an illegal action
(this includes a null actions string)public boolean implies(java.security.Permission p)
java.* implies java.home implies in class java.security.BasicPermissionp - the permission to checkpublic boolean equals(java.lang.Object obj)
equals in class java.security.BasicPermissionobj - the other objectObject.hashCode()public int hashCode()
getName().hashCode().hashCode in class java.security.BasicPermissionObject.equals(Object),
System.identityHashCode(Object)public java.lang.String getActions()
getActions in class java.security.BasicPermissionpublic java.security.PermissionCollection newPermissionCollection()
newPermissionCollection in class java.security.BasicPermission