Package org.jruby.java.proxies
Class JavaInterfaceTemplate.BlockInterfaceImpl
java.lang.Object
org.jruby.internal.runtime.methods.DynamicMethod
org.jruby.internal.runtime.methods.JavaMethod
org.jruby.java.proxies.JavaInterfaceTemplate.BlockInterfaceImpl
- All Implemented Interfaces:
Cloneable,MethodArgs2,NativeCallMethod
- Enclosing class:
- JavaInterfaceTemplate
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate final classNested classes/interfaces inherited from class org.jruby.internal.runtime.methods.JavaMethod
JavaMethod.JavaMethodN, JavaMethod.JavaMethodNBlock, JavaMethod.JavaMethodOne, JavaMethod.JavaMethodOneBlock, JavaMethod.JavaMethodOneOrN, JavaMethod.JavaMethodOneOrNBlock, JavaMethod.JavaMethodOneOrTwo, JavaMethod.JavaMethodOneOrTwoBlock, JavaMethod.JavaMethodOneOrTwoOrN, JavaMethod.JavaMethodOneOrTwoOrNBlock, JavaMethod.JavaMethodOneOrTwoOrThree, JavaMethod.JavaMethodOneOrTwoOrThreeBlock, JavaMethod.JavaMethodOneOrTwoOrThreeOrN, JavaMethod.JavaMethodOneOrTwoOrThreeOrNBlock, JavaMethod.JavaMethodThree, JavaMethod.JavaMethodThreeBlock, JavaMethod.JavaMethodThreeOrN, JavaMethod.JavaMethodThreeOrNBlock, JavaMethod.JavaMethodTwo, JavaMethod.JavaMethodTwoBlock, JavaMethod.JavaMethodTwoOrN, JavaMethod.JavaMethodTwoOrNBlock, JavaMethod.JavaMethodTwoOrThree, JavaMethod.JavaMethodTwoOrThreeBlock, JavaMethod.JavaMethodTwoOrThreeOrN, JavaMethod.JavaMethodTwoOrThreeOrNBlock, JavaMethod.JavaMethodZero, JavaMethod.JavaMethodZeroBlock, JavaMethod.JavaMethodZeroOrN, JavaMethod.JavaMethodZeroOrNBlock, JavaMethod.JavaMethodZeroOrOne, JavaMethod.JavaMethodZeroOrOneBlock, JavaMethod.JavaMethodZeroOrOneOrN, JavaMethod.JavaMethodZeroOrOneOrNBlock, JavaMethod.JavaMethodZeroOrOneOrTwo, JavaMethod.JavaMethodZeroOrOneOrTwoBlock, JavaMethod.JavaMethodZeroOrOneOrTwoOrN, JavaMethod.JavaMethodZeroOrOneOrTwoOrNBlock, JavaMethod.JavaMethodZeroOrOneOrTwoOrThree, JavaMethod.JavaMethodZeroOrOneOrTwoOrThreeBlock, JavaMethod.JavaMethodZeroOrOneOrTwoOrThreeOrN, JavaMethod.JavaMethodZeroOrOneOrTwoOrThreeOrNBlockNested classes/interfaces inherited from class org.jruby.internal.runtime.methods.DynamicMethod
DynamicMethod.NativeCall, DynamicMethod.Version -
Field Summary
FieldsFields inherited from class org.jruby.internal.runtime.methods.JavaMethod
BLOCK_METHODS, BLOCK_REST_METHODS, METHODS, NAME_PASSER, nativeCall, REST, REST_METHODS, signature, staticScopeFields inherited from class org.jruby.internal.runtime.methods.DynamicMethod
definedClass, flags, handle, implementationClass, name, protectedClass, serialNumber -
Constructor Summary
ConstructorsConstructorDescriptionBlockInterfaceImpl(RubyClass implClass, Block implBlock, IRubyObject[] methodNames) -
Method Summary
Modifier and TypeMethodDescriptionfinal IRubyObjectcall(ThreadContext context, IRubyObject self, RubyModule klazz, String name, Block block) Arity 0, with block; calls through IRubyObject[] pathcall(ThreadContext context, IRubyObject self, RubyModule clazz, String name, IRubyObject[] args, Block block) The minimum 'call' method required for a dynamic method handle.final IRubyObjectcall(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, Block block) Arity 1, with block; calls through IRubyObject[] pathfinal IRubyObjectcall(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, IRubyObject arg1, Block block) Arity 2, with block; calls through IRubyObject[] pathfinal IRubyObjectcall(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, IRubyObject arg1, IRubyObject arg2, Block block) Arity 3, with block; calls through IRubyObject[] pathprivate IRubyObjectcallImpl(ThreadContext context, RubyModule clazz, Block block, IRubyObject... args) dup()Duplicate this method, returning DynamicMethod referencing the same code and with the same attributes.(package private) final JavaInterfaceTemplate.BlockInterfaceImpl.ConcreteMethodgetConcreteMethod(String name) Methods inherited from class org.jruby.internal.runtime.methods.JavaMethod
callTrace, callTraceCompiled, checkArgumentCount, getArity, getCallerRequirement, getJavaName, getNativeCall, getParameterList, getSignature, getStaticScope, isNative, isSingleton, postBacktraceAndScope, postBacktraceDummyScope, postBacktraceOnly, postFrameAndScope, postFrameOnly, postNoFrameDummyScope, postNoop, postScopeOnly, preBacktraceAndScope, preBacktraceDummyScope, preBacktraceOnly, preFrameAndDummyScope, preFrameAndDummyScope, preFrameAndScope, preFrameAndScope, preFrameOnly, preFrameOnly, preNoFrameDummyScope, preNoop, preScopeOnly, raiseArgumentError, returnTrace, returnTraceCompiled, setArity, setCallerRequirement, setJavaName, setNativeCall, setNativeCall, setParameterDesc, setParameterList, setSignature, setSingletonMethods inherited from class org.jruby.internal.runtime.methods.DynamicMethod
calculateProtectedClass, call, call, call, call, call, callRespondTo, getCallConfig, getDefinedClass, getHandle, getImplementationClass, getInstanceVariableNames, getMethodData, getName, getProtectedClass, getRealMethod, getSerialNumber, getVisibility, init, init, isBuiltin, isCallableFrom, isImplementedBy, isNotImplemented, isNull, isRefined, isUndefined, setCallConfig, setDefinedClass, setHandle, setImplementationClass, setIsBuiltin, setNotImplemented, setVisibility
-
Field Details
-
methodNames
-
implBlock
-
-
Constructor Details
-
BlockInterfaceImpl
BlockInterfaceImpl(RubyClass implClass, Block implBlock, IRubyObject[] methodNames)
-
-
Method Details
-
call
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule clazz, String name, IRubyObject[] args, Block block) Description copied from class:DynamicMethodThe minimum 'call' method required for a dynamic method handle. Subclasses must implement this method, but may implement the other signatures to provide faster, non-boxing call paths. Typically subclasses will implement this method to check variable arity calls, then performing a specific-arity invocation to the appropriate method or performing variable-arity logic in-line.- Specified by:
callin classDynamicMethod- Parameters:
context- The thread context for the currently executing threadself- The 'self' or 'receiver' object to use for this callclazz- The Ruby class against which this method is bindingname- The incoming name used to invoke this methodargs- The argument list to this invocationblock- The block passed to this invocation- Returns:
- The result of the call
-
callImpl
private IRubyObject callImpl(ThreadContext context, RubyModule clazz, Block block, IRubyObject... args) -
call
public final IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, Block block) Description copied from class:DynamicMethodArity 0, with block; calls through IRubyObject[] path- Overrides:
callin classDynamicMethod
-
call
public final IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, Block block) Description copied from class:DynamicMethodArity 1, with block; calls through IRubyObject[] path- Overrides:
callin classDynamicMethod
-
call
public final IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, IRubyObject arg1, Block block) Description copied from class:DynamicMethodArity 2, with block; calls through IRubyObject[] path- Overrides:
callin classDynamicMethod
-
call
public final IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg0, IRubyObject arg1, IRubyObject arg2, Block block) Description copied from class:DynamicMethodArity 3, with block; calls through IRubyObject[] path- Overrides:
callin classDynamicMethod
-
dup
Description copied from class:DynamicMethodDuplicate this method, returning DynamicMethod referencing the same code and with the same attributes. It is not required that this method produce a new object if the semantics of the DynamicMethod subtype do not require such.- Overrides:
dupin classJavaMethod- Returns:
- An identical DynamicMethod object to the target.
-
getConcreteMethod
-