| java.lang.Object java.security.GuardedObject
GuardedObject | public class GuardedObject implements Serializable(Code) | | GuardedObject controls access to an object, by checking all requests for the
object with a Guard.
|
Constructor Summary | |
public | GuardedObject(Object object, Guard guard) Constructs a GuardedObject to protect access to the specified Object
using the specified Guard. |
Method Summary | |
public Object | getObject() Checks whether access should be granted to the object. |
GuardedObject | public GuardedObject(Object object, Guard guard)(Code) | | Constructs a GuardedObject to protect access to the specified Object
using the specified Guard.
Parameters: object - the Object to guard Parameters: guard - the Guard |
getObject | public Object getObject() throws SecurityException(Code) | | Checks whether access should be granted to the object. If access is
granted, this method returns the object. If it is not granted, then a
SecurityException is thrown.
the guarded object exception: java.lang.SecurityException - If access is not granted to the object |
|
|