jruby/docs BETA
Navigation
org.jruby.internal.runtime.methods 34
C AliasMethod
C AttrReaderMethod
C AttrWriterMethod
I CacheableMethod
E CallConfiguration
C CompiledIRMethod
C CompiledIRNoProtocolMethod
C DefineMethodMethod
C DelegatingDynamicMethod
C DescriptorInfo
C DumpingInvocationMethodFactory
C DynamicMethod
C ExitableReturn
E Framing
C HandleMethod
I IRMethodArgs
C InterpretedIRBodyMethod
C InterpretedIRMethod
C InvocationMethodFactory
C InvokeDynamicMethodFactory
C JavaMethod
I MethodArgs2
C MethodMethod
C MixedModeIRMethod
I NativeCallMethod
C NullMethod
C PartialDelegatingMethod
C ProcMethod
C ProfilingDynamicMethod
C RefinedMarker
C RefinedWrapper
E Scoping
C SynchronizedDynamicMethod
C UndefinedMethod
AliasMethod — members 18+
C new(implementation_class, entry, new_name, old_name)
M call(context, self, klazz, unused) IRubyObject
M call(context, self, klazz, unused, arg) IRubyObject
M call(context, self, klazz, unused, arg1, arg2) IRubyObject
M call(context, self, klazz, unused, arg1, arg2, arg3) IRubyObject
M call(context, self, klazz, unused, args) IRubyObject
M call(context, self, klazz, unused, block) IRubyObject
M call(context, self, klazz, unused, arg1, block) IRubyObject
M call(context, self, klazz, unused, arg1, arg2, block) IRubyObject
M call(context, self, klazz, unused, arg1, arg2, arg3, block) IRubyObject
M call(context, self, klazz, unused, args, block) IRubyObject
M dup() DynamicMethod
M native?() boolean
M old_name() String
M real_method() DynamicMethod
M serial_number() long
C set_ruby2_keywords()
M signature() Signature
from DynamicMethod
C adjust_alias_count(delta)
M alias_count() int
M builtin?() boolean
M call_respond_to(context, self, respond_to_method_name, klazz, name) boolean
M defined_class() RubyModule
C defined_class=(defined_class)
M handle() Object
C handle=(handle)
M implementation_class() RubyModule
C implementation_class=(impl_class)
M instance_variable_names() Collection<String>
C is_builtin=(is_builtin)
M is_callable_from(caller, call_type) boolean
M is_implemented_by(other) boolean
M method_data() MethodData
M name() String
C not_implemented=(set_not_implemented)
M not_implemented?() boolean
M null?() boolean
M refined?() boolean
M undefined?() boolean
M visibility() Visibility
C visibility=(visibility)

org.jruby.internal.runtime.methods.AliasMethod

class extends DynamicMethod 18 members

Represents a method which has been aliased. Aliased methods pass as frame class the implementationClass they were created with, which should reflect the level in the related class hierarchy where the alias appears. This allows aliased methods that super to do so from the appropriate starting level.

Constructors

new

new ( RubyModule implementation_class, CacheEntry entry, String new_name, String old_name )
Java: <init>(org.jruby.RubyModule implementationClass, org.jruby.runtime.callsite.CacheEntry entry, String newName, String oldName)

For some java native methods it is convenient to pass in a String instead of a ByteList.

Instance Methods

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2 )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg1, org.jruby.runtime.builtin.IRubyObject arg2)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3 )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg1, org.jruby.runtime.builtin.IRubyObject arg2, org.jruby.runtime.builtin.IRubyObject arg3)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject[] args )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject[] args)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, Block block )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.Block block)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, Block block )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg1, org.jruby.runtime.Block block)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, Block block )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg1, org.jruby.runtime.builtin.IRubyObject arg2, org.jruby.runtime.Block block)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3, Block block )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject arg1, org.jruby.runtime.builtin.IRubyObject arg2, org.jruby.runtime.builtin.IRubyObject arg3, org.jruby.runtime.Block block)

call

IRubyObject call ( ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject[] args, Block block )
Java: call(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.RubyModule klazz, String unused, org.jruby.runtime.builtin.IRubyObject[] args, org.jruby.runtime.Block block)

dup

DynamicMethod dup ( )
Java: dup()

native?

boolean native? ( )
Java: isNative() · also: is_native

old_name

String old_name ( )
Java: getOldName() · also: get_old_name

real_method

DynamicMethod real_method ( )
Java: getRealMethod() · also: get_real_method

serial_number

long serial_number ( )
Java: getSerialNumber() · also: get_serial_number

set_ruby2_keywords

set_ruby2_keywords ( )
Java: setRuby2Keywords()

signature

Signature signature ( )
Java: getSignature() · also: get_signature

Inherited

from DynamicMethod

adjust_alias_count

adjust_alias_count ( int delta )
Java: adjustAliasCount(int delta)

alias_count

int alias_count ( )
Java: getAliasCount() · also: get_alias_count

builtin?

boolean builtin? ( )
Java: isBuiltin() · also: is_builtin

Whether this method is a builtin method, i.e. a method built-in to JRuby and loaded during its core boot process.

Returns: true if this is a core built-in method, false otherwise

call_respond_to

boolean call_respond_to ( ThreadContext context, IRubyObject self, String respond_to_method_name, RubyModule klazz, RubySymbol name )
Java: callRespondTo(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, String respondToMethodName, org.jruby.RubyModule klazz, org.jruby.RubySymbol name)

defined_class

RubyModule defined_class ( )
Java: getDefinedClass() · also: get_defined_class

Get the original owner of this method/

Returns: the module method was defined in

defined_class=

defined_class= ( RubyModule defined_class )
Java: setDefinedClass(org.jruby.RubyModule definedClass) · also: set_defined_class

Set the defining class for this method, as when restructuring hierarchy for prepend.

nametypedescription
defined_classorg.jruby.RubyModulethat method was defined in

handle

Object handle ( )
Java: getHandle() · also: get_handle

Get the "handle" associated with this DynamicMethod.

Returns: the handle

handle=

handle= ( Object handle )
Java: setHandle(Object handle) · also: set_handle

Set the "handle" associated with this DynamicMethod.

nametypedescription
handleObjectthe handle

implementation_class

RubyModule implementation_class ( )
Java: getImplementationClass() · also: get_implementation_class

Retrieve the class or module on which this method is implemented, used for 'super' logic among others.

Returns: The class on which this method is implemented

implementation_class=

implementation_class= ( RubyModule impl_class )
Java: setImplementationClass(org.jruby.RubyModule implClass) · also: set_implementation_class

Set the class on which this method is implemented, used for 'super' logic, among others.

nametypedescription
impl_classorg.jruby.RubyModuleThe class on which this method is implemented

instance_variable_names

Collection<String> instance_variable_names ( )
Java: getInstanceVariableNames() · also: get_instance_variable_names

is_builtin=

is_builtin= ( boolean is_builtin )
Java: setIsBuiltin(boolean isBuiltin) · also: set_is_builtin

Force this method to be treated as a core built-in method if true, or as a normal non-core method otherwise.

nametypedescription
is_builtinbooleantrue if this is a core built-in method, false otherwise

is_callable_from

boolean is_callable_from ( IRubyObject caller, CallType call_type )
Java: isCallableFrom(org.jruby.runtime.builtin.IRubyObject caller, org.jruby.runtime.CallType callType)

Determine whether this method is callable from the given object using the given call type.

nametypedescription
callerorg.jruby.runtime.builtin.IRubyObjectThe calling object
call_typeorg.jruby.runtime.CallTypeThe type of call

Returns: true if the call would not violate visibility; false otherwise

is_implemented_by

boolean is_implemented_by ( RubyModule other )
Java: isImplementedBy(org.jruby.RubyModule other)

method_data

MethodData method_data ( )
Java: getMethodData() · also: get_method_data

Additional metadata about this method.

Returns: method data (defined in sub classes)

name

String name ( )
Java: getName() · also: get_name

Get the base name this method was defined as.

Returns: the base name for the method

not_implemented=

not_implemented= ( boolean set_not_implemented )
Java: setNotImplemented(boolean setNotImplemented) · also: set_not_implemented

Set whether this method is "not implemented".

nametypedescription
set_not_implementedbooleanis this not implement or not

not_implemented?

boolean not_implemented? ( )
Java: isNotImplemented() · also: is_not_implemented

Whether this method is "not implemented". This is primarily to support Ruby 1.9's behavior of respond_to? yielding false if the feature in question is unsupported (but still having the method defined).

Returns: is this a method which is marked as not implemented

null?

boolean null? ( )
Java: isNull() · also: is_null

Whether this method is the "null" method, used to stop method name resolution loops. Only returns true for NullMethod instances, of which there should be only one (a singleton).

Returns: true if this method is the undefined method; false otherwise

refined?

boolean refined? ( )
Java: isRefined() · also: is_refined

undefined?

boolean undefined? ( )
Java: isUndefined() · also: is_undefined

Whether this method is the "undefined" method, used to represent a missing or undef'ed method. Only returns true for UndefinedMethod instances, of which there should be only one (a singleton).

Returns: true if this method is the undefined method; false otherwise

visibility

Visibility visibility ( )
Java: getVisibility() · also: get_visibility

Get the visibility of this method.

Returns: The visibility of this method

visibility=

visibility= ( Visibility visibility )
Java: setVisibility(org.jruby.runtime.Visibility visibility) · also: set_visibility

Set the visibility of this method.

nametypedescription
visibilityorg.jruby.runtime.VisibilityThe visibility of this method