|
Example Privileged Code
- Must use java.security.PrivilegedAction
interface
- The run() method contains code needing
privilege
- AccessController.doPrivileged()
- Takes PrivilegedAction object argument
- Invokes its run() method
- Returns the run() method's return value
|
copyright © 2014 - all rights riserved by javatechnologycenter.com