public class SharedClassPermission
extends java.security.BasicPermission
Usage:
To grant permission to a ClassLoader, add permission in the java.policy
file.
For example,
com.ibm.oti.shared.SharedClassPermission "classloaders.myClassLoader", "read,write";
Possible actions are:
Constructor and Description |
---|
SharedClassPermission(java.lang.ClassLoader loader,
java.lang.String actions)
Constructs a new instance of this class.
|
SharedClassPermission(java.lang.String classLoaderClassName,
java.lang.String actions)
Constructs a new instance of this class.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o)
Compares the argument to the receiver, and answers
true
if they represent the same object using a class
specific comparison. |
java.lang.String |
getActions()
Answers the actions associated with the receiver.
|
int |
hashCode()
Answers the integer hash code for the receiver.
|
boolean |
implies(java.security.Permission permission)
Indicates whether the argument permission is implied
by the receiver.
|
java.security.PermissionCollection |
newPermissionCollection()
Answers a new PermissionCollection for holding permissions
of this class.
|
public SharedClassPermission(java.lang.ClassLoader loader, java.lang.String actions)
loader
- ClassLoader the ClassLoader requiring the permissionactions
- String the actions which are applicable to itpublic SharedClassPermission(java.lang.String classLoaderClassName, java.lang.String actions)
classLoaderClassName
- String the name of the ClassLoader class requiring the permissionactions
- String the actions which are applicable to itpublic boolean equals(java.lang.Object o)
true
if they represent the same object using a class
specific comparison.
In this case, the receiver must be for the same property as the argument, and must have the same actions.
equals
in class java.security.BasicPermission
o
- the object to compare with this objecttrue
if the object is the same as this object,
false
if it is different from this objecthashCode()
public java.security.PermissionCollection newPermissionCollection()
newPermissionCollection
in class java.security.BasicPermission
PermissionCollection
public int hashCode()
Any two objects which answer true
when passed to
equals
must answer the same value for this method.
hashCode
in class java.security.BasicPermission
equals(java.lang.Object)
public java.lang.String getActions()
The result will be either "read", "write", or "read,write".
getActions
in class java.security.BasicPermission
public boolean implies(java.security.Permission permission)
implies
in class java.security.BasicPermission
permission
- Permission the permission to checktrue
if the argument permission is implied
by the receiver, and false
if it is notEclipse OpenJ9 website.
To raise a bug report or suggest an improvement create an Eclipse OpenJ9 issue.
Copyright © 1998, 2023 IBM Corp. and others.