|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.soton.itinnovation.grid.pbac2.pep.DynamicPEP<T>
public class DynamicPEP<T>
This class creates a proxy object that wraps an object with a PEP.
Calling a method on the proxy object will call PDP.lockAndCheck(java.lang.String, uk.ac.soton.itinnovation.grid.types.SubjectDescription, java.lang.String) first, then
call the wrapped object's method, and then unlock the resource.
The action is the name of the method being invoked.
| Method Summary | ||
|---|---|---|
static
|
dynamicPEP(Class<T> iface)
Create a proxy for 'iface', where all public methods are PEP-wrapped. |
|
static
|
dynamicPEP(Class<T> iface,
T impl,
String resource,
SubjectDescription subject)
Create a proxy for 'iface', where all public methods are PEP-wrapped. |
|
Object |
invoke(Object proxy,
Method method,
Object[] args)
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static <T> T dynamicPEP(Class<T> iface)
iface - the interface of the service to test (see ImplementationFactory)
public static <T> T dynamicPEP(Class<T> iface,
T impl,
String resource,
SubjectDescription subject)
iface - the interface of the object to wrapimpl - an implementation of iface, or null to get one using the ImplementationFactoryresource - the PBAC resource being protected, or null to use ProcessContextHelper.getProcessContext()subject - the user accessing the resource, or null to use AuthenticatedContextHelper.getCurrentUser()
public Object invoke(Object proxy,
Method method,
Object[] args)
throws Throwable
invoke in interface InvocationHandlerThrowable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||