public abstract class Selector
extends Object
Base state holder for invokedynamic method, property, constructor, and cast selection.
| Modifiers | Name | Description |
|---|---|---|
Object[] |
args |
Effective invocation arguments, possibly after spread-call normalization. |
CacheableCallSite |
callSite |
Call site being linked. |
IndyInterface.CallType |
callType |
Call-site category associated with this selector. |
boolean |
catchException |
Controls whether Groovy runtime exceptions are unwrapped around the target. |
MethodHandle |
handle |
Method handle assembled for the current dispatch path. |
boolean |
isVargs |
Indicates whether the selected target accepts varargs. |
MetaMethod |
method |
Selected meta method, when method dispatch resolves through the metaclass. |
String |
name |
Name of the method or property being resolved. |
boolean |
safeNavigation |
Flags tracking safe navigation and spread-call semantics. |
Class<?> |
selectionBase |
Class used as the selection base for metaclass lookups. |
Class<?> |
sender |
Sending class used for visibility and MOP decisions. |
boolean |
skipSpreadCollector |
Indicates whether spread-collector adaptation should be skipped. |
MethodType |
targetType |
Call-site target type and the currently adapted working type. |
boolean |
thisCall |
Indicates whether the invocation is a this call. |
boolean |
useMetaClass |
Flags controlling metaclass fallback usage and call-site caching. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
public Object |
getCorrectedReceiver()Returns NullObject.getNullObject if the receiver (args[0]) is null. |
|
public static Selector |
getSelector(CacheableCallSite callSite, Class<?> sender, String methodName, int callID, boolean safeNavigation, boolean thisCall, boolean spreadCall, Object[] arguments)Returns a Selector or throws a GroovyBugError. |
Effective invocation arguments, possibly after spread-call normalization.
Call site being linked.
Call-site category associated with this selector.
Controls whether Groovy runtime exceptions are unwrapped around the target.
Method handle assembled for the current dispatch path.
Indicates whether the selected target accepts varargs.
Selected meta method, when method dispatch resolves through the metaclass.
Name of the method or property being resolved.
Flags tracking safe navigation and spread-call semantics.
Class used as the selection base for metaclass lookups.
Sending class used for visibility and MOP decisions.
Indicates whether spread-collector adaptation should be skipped.
Call-site target type and the currently adapted working type.
Indicates whether the invocation is a this call.
Flags controlling metaclass fallback usage and call-site caching.
Returns NullObject.getNullObject if the receiver (args[0]) is null. If it is not null, the receiver itself is returned.
Returns a Selector or throws a GroovyBugError.