public interface Invoker extends Serializable
During the execution of CPS code, Invoker is available from Env.getInvoker().
Env.getInvoker(),
Continuable.Continuable(Script, Env),
Envs.empty(Invoker),
"doc/sandbox.md"| Modifier and Type | Field and Description |
|---|---|
static Invoker |
INSTANCE
Default instance to be used.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
constructorCall(Class lhs,
Object[] args) |
Invoker |
contextualize(CallSiteBlock tags)
Returns a child
Invoker used to make a call on behalf of the given CallSiteBlock. |
Object |
getArray(Object lhs,
Object index) |
Object |
getAttribute(Object lhs,
String name) |
Object |
getProperty(Object lhs,
String name) |
Object |
methodCall(Object receiver,
String method,
Object[] args) |
Object |
methodPointer(Object lhs,
String name) |
void |
setArray(Object lhs,
Object index,
Object value) |
void |
setAttribute(Object lhs,
String name,
Object value) |
void |
setProperty(Object lhs,
String name,
Object value) |
Object |
superCall(Class senderType,
Object receiver,
String method,
Object[] args)
Invokespecial equivalent used for "super.foo(...)" kind of method call.
|
static final Invoker INSTANCE
Object methodCall(Object receiver, String method, Object[] args) throws Throwable
ThrowableObject superCall(Class senderType, Object receiver, String method, Object[] args) throws Throwable
senderType - The type of the current method. Resolution of 'super' depends on this.
'receiver' is an instance of this type.receiver - Instance that gets the method callThrowablevoid setProperty(Object lhs, String name, Object value) throws Throwable
Throwablevoid setAttribute(Object lhs, String name, Object value) throws Throwable
ThrowableInvoker contextualize(CallSiteBlock tags)
Invoker used to make a call on behalf of the given CallSiteBlock.Copyright © 2011–2019. All rights reserved.