|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.thoughtworks.proxy.toys.delegate.DelegatingInvoker<T> com.thoughtworks.proxy.toys.privilege.PrivilegingInvoker<T>
public class PrivilegingInvoker<T>
Invoker
that creates for the invoked method a
PrivilegedExceptionAction
and runs this action with the provided
ActionExecutor
.
Constructor Summary | |
---|---|
PrivilegingInvoker(ProxyFactory proxyFactory,
ObjectReference<T> delegateReference,
ActionExecutor executor)
Construct the invoker. |
|
PrivilegingInvoker(T delegate)
Construct the invoker using a AccessControllerExecutor . |
|
PrivilegingInvoker(T delegate,
ActionExecutor executor)
Construct the invoker. |
Method Summary | |
---|---|
protected Object |
invokeOnDelegate(Method method,
Object[] args)
Invoke the given method on the delegate. |
Methods inherited from class com.thoughtworks.proxy.toys.delegate.DelegatingInvoker |
---|
delegate, equals, getDelegateReference, getMethodToInvoke, getProxyFactory, hashCode, invoke |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PrivilegingInvoker(ProxyFactory proxyFactory, ObjectReference<T> delegateReference, ActionExecutor executor)
proxyFactory
- the proxy factory used to create the proxydelegateReference
- the reference object managing the delegate for the callexecutor
- the executor of the PrivilegedExceptionAction
public PrivilegingInvoker(T delegate, ActionExecutor executor)
delegate
- the delegate for the callexecutor
- the executor of the PrivilegedExceptionAction
public PrivilegingInvoker(T delegate)
AccessControllerExecutor
.
delegate
- the delegate for the callMethod Detail |
---|
protected Object invokeOnDelegate(Method method, Object[] args) throws InvocationTargetException
DelegatingInvoker
invokeOnDelegate
in class DelegatingInvoker<T>
method
- the method to invokeargs
- the arguments for the invocation
InvocationTargetException
- if the invoked method throws any exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |