An instance of this class can be used as the argument of {@link AccessController#doPrivileged(PrivilegedAction) AccessController.doPrivileged} or {@link Security#doPrivileged(PrivilegedAction) Security.doPrivileged}.
The following code retrieves the value of the system property named "prop"
as a privileged action:
String s = (String) String.doPrivileged( new GetPropertyAction("prop"));
If the protection domain of the immediate caller of doPrivileged
or the protection domain of this class does not imply the permissions necessary for the operation, the behavior is as if the system property is not defined.
@author Sun Microsystems, Inc.
@see PrivilegedAction
@see AccessController
@see Security
@since 2.0
|
|