EmbedRubyObjectAdapter. Users get an instance of this
class by newObjectAdapter() method of ScriptingContainer.
| Modifier and Type | Class and Description |
|---|---|
| public static enum | EmbedRubyObjectAdapterImpl.
Deprecated
|
| Modifier and Type | Field and Description |
|---|---|
| private final RubyObjectAdapter | |
| private final ScriptingContainer | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| private void | |
| public IRubyObject | callMethod(IRubyObject receiver, String methodName)
Implements org.
|
| public IRubyObject | callMethod(IRubyObject receiver, String methodName, IRubyObject singleArg)
Implements org.
|
| public IRubyObject | callMethod(IRubyObject receiver, String methodName, IRubyObject[] args)
Implements org.
|
| public IRubyObject | callMethod(IRubyObject receiver, String methodName, IRubyObject[] args, Block block)
Implements org.
|
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Class<T> is the type we want it to convert to returnType)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object is an method argument singleArg, Class<T> returnType is the type we want it to convert to returnType)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object[] is an array of method arguments args, Class<T> is the type we want it to convert to returnType)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object[] is an array of method arguments except a block args, Block is a block to be executed in this method block, Class<T> is the type we want it to convert to returnType)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Class<T> is the type we want it to convert to returnType, EmbedEvalUnit is parsed unit unit)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object[] is an array of method arguments args, Class<T> is the type we want it to convert to returnType, EmbedEvalUnit is parsed unit unit)Implements org. Executes a method defined in Ruby script. |
| public <T> T | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object[] is an array of method arguments except a block args, Block is a block to be executed in this method block, Class<T> is the type we want it to convert to returnType, EmbedEvalUnit is parsed unit unit)Implements org. Executes a method defined in Ruby script. |
| public Object | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Object... are method arguments. args)Implements org. Executes a method defined in Ruby script. |
| public Object | callMethod(Object
is an instance that will receive this method call receiver, String is a method name to be called methodName, Block is a block to be executed in this method block, Object... is an array of method arguments except a block args)Implements org. Executes a method defined in Ruby script. |
| public IRubyObject | callSuper(IRubyObject receiver, IRubyObject[] args)
Implements org.
|
| public IRubyObject | callSuper(IRubyObject receiver, IRubyObject[] args, Block block)
Implements org.
|
| public <T> T | callSuper(Object
is an instance that will receive this method call receiver, Object[] is an array of method arguments args, Class<T> is the type we want it to convert to returnType)Implements org.
|
| public <T> T | callSuper(Object
is an instance that will receive this method call receiver, Object[] is an array of method arguments except a block args, Block is a block to be executed in this method block, Class<T> is the type we want it to convert to returnType)Implements org.
|
| private static IRubyObject[] | |
| public IRubyObject[] | |
| public RubyInteger | |
| public RubyString | |
| private <T> T | doInvokeMethod(Class<T> returnType, IRubyObject rubyReceiver, String methodName, Block block, EmbedEvalUnit unit, Object... args)
|
| private <T> T | doInvokeSuper(Class<T> returnType, IRubyObject rubyReceiver, Block block, EmbedEvalUnit unit, Object... args)
|
| public IRubyObject | getInstanceVariable(IRubyObject obj, String variableName)
Implements org.
|
| private IRubyObject | |
| private IRubyObject | |
| public boolean | |
| public <T> T | runRubyMethod(Class<T>
is the type we want it to convert to returnType, Object is an instance that will receive this method call. The receiver
can be null or other Java objects. The null will be converted to
RubyNil or wrapped in RubyObject. receiver, String is a method name to be called methodName, Block is an optional Block object. Send null for no block. block, Object... is an array of method arguments args)Implements org. Executes a method defined in Ruby script. |
| public IRubyObject | setInstanceVariable(IRubyObject obj, String variableName, IRubyObject value)
Implements org.
|
| adapter | back to summary |
|---|---|
| private final RubyObjectAdapter adapter | |
| container | back to summary |
|---|---|
| private final ScriptingContainer container | |
| wrapExceptions | back to summary |
|---|---|
| private final boolean wrapExceptions | |
| EmbedRubyObjectAdapterImpl | back to summary |
|---|---|
| public EmbedRubyObjectAdapterImpl(ScriptingContainer container) | |
| EmbedRubyObjectAdapterImpl | back to summary |
|---|---|
| public EmbedRubyObjectAdapterImpl(ScriptingContainer container, boolean wrapExceptions) | |
| afterSharingVariablesCall | back to summary |
|---|---|
| private void afterSharingVariablesCall(final ThreadContext context) | |
| beforeSharingVariablesCall | back to summary |
|---|---|
| private void beforeSharingVariablesCall(final ThreadContext context, EmbedEvalUnit unit) | |
| callMethod | back to summary |
|---|---|
| public IRubyObject callMethod(IRubyObject receiver, String methodName) Implements org. | |
| callMethod | back to summary |
|---|---|
| public IRubyObject callMethod(IRubyObject receiver, String methodName, IRubyObject singleArg) Implements org. | |
| callMethod | back to summary |
|---|---|
| public IRubyObject callMethod(IRubyObject receiver, String methodName, IRubyObject[] args) Implements org. | |
| callMethod | back to summary |
|---|---|
| public IRubyObject callMethod(IRubyObject receiver, String methodName, IRubyObject[] args, Block block) Implements org. | |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Class<T> returnType) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method does not have any argument. | |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Object singleArg, Class<T> returnType) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method have only one argument. | |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Object[] args, Class<T> returnType) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method have multiple arguments. | |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Object[] args, Block block, Class<T> returnType) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method have multiple arguments, one of which is a block.
| |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Class<T> returnType, EmbedEvalUnit unit) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method does not have any argument, and users want to inject Ruby's local variables' values from Java.
| |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Object[] args, Class<T> returnType, EmbedEvalUnit unit) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method have multiple arguments, and users want to inject Ruby's local variables' values from Java.
| |
| callMethod | back to summary |
|---|---|
| public <T> T callMethod(Object receiver, String methodName, Object[] args, Block block, Class<T> returnType, EmbedEvalUnit unit) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method have multiple arguments, one of which is a block, and users want to inject Ruby's local variables' values from Java.
| |
| callMethod | back to summary |
|---|---|
| public Object callMethod(Object receiver, String methodName, Object... args) Implements org. Doc from org. Executes a method defined in Ruby script. | |
| callMethod | back to summary |
|---|---|
| public Object callMethod(Object receiver, String methodName, Block block, Object... args) Implements org. Doc from org. Executes a method defined in Ruby script. This method is used when a Ruby method has a block in its arguments. | |
| callSuper | back to summary |
|---|---|
| public IRubyObject callSuper(IRubyObject receiver, IRubyObject[] args) Implements org. | |
| callSuper | back to summary |
|---|---|
| public IRubyObject callSuper(IRubyObject receiver, IRubyObject[] args, Block block) Implements org. | |
| callSuper | back to summary |
|---|---|
| public <T> T callSuper(Object receiver, Object[] args, Class<T> returnType) Implements org.
| |
| callSuper | back to summary |
|---|---|
| public <T> T callSuper(Object receiver, Object[] args, Block block, Class<T> returnType) Implements org.
| |
| convertArgs | back to summary |
|---|---|
private static IRubyObject[] convertArgs(final Ruby runtime, final Object[] args)
| |
| convertToJavaArray | back to summary |
|---|---|
| public IRubyObject[] convertToJavaArray(IRubyObject array) Implements org. | |
| convertToRubyInteger | back to summary |
|---|---|
| public RubyInteger convertToRubyInteger(IRubyObject obj) Implements org. | |
| convertToRubyString | back to summary |
|---|---|
| public RubyString convertToRubyString(IRubyObject obj) Implements org. | |
| doInvokeMethod | back to summary |
|---|---|
| private <T> T doInvokeMethod(Class<T> returnType, IRubyObject rubyReceiver, String methodName, Block block, EmbedEvalUnit unit, Object... args) | |
| doInvokeSuper | back to summary |
|---|---|
| private <T> T doInvokeSuper(Class<T> returnType, IRubyObject rubyReceiver, Block block, EmbedEvalUnit unit, Object... args) | |
| getInstanceVariable | back to summary |
|---|---|
| public IRubyObject getInstanceVariable(IRubyObject obj, String variableName) Implements org. | |
| getReceiverObject | back to summary |
|---|---|
| private IRubyObject getReceiverObject(Object receiver) | |
| getTopSelf | back to summary |
|---|---|
| private IRubyObject getTopSelf() | |
| isKindOf | back to summary |
|---|---|
| public boolean isKindOf(IRubyObject value, RubyModule rubyModule) Implements org. | |
| runRubyMethod | back to summary |
|---|---|
| public <T> T runRubyMethod(Class<T> returnType, Object receiver, String methodName, Block block, Object... args) Implements org. Doc from org. Executes a method defined in Ruby script.
| |
| setInstanceVariable | back to summary |
|---|---|
| public IRubyObject setInstanceVariable(IRubyObject obj, String variableName, IRubyObject value) Implements org. | |
Deprecated
| Modifier and Type | Field and Description |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. | CALLMETHOD
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| public static final EmbedRubyObjectAdapterImpl. | CALLMETHOD_NOARG
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| public static final EmbedRubyObjectAdapterImpl. | CALLMETHOD_WITHBLOCK
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| public static final EmbedRubyObjectAdapterImpl. | CALLSUPER
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| public static final EmbedRubyObjectAdapterImpl. | CALLSUPER_WITHBLOCK
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static EmbedRubyObjectAdapterImpl. | valueOf(String name)
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| public static EmbedRubyObjectAdapterImpl. | values()
References Deprecated
EmbedRubyObjectAdapterImpl.MethodType is deprecated or references (maybe indirectly) at least one deprecated element.
|
| CALLMETHOD | back to summary |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| CALLMETHOD_NOARG | back to summary |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| CALLMETHOD_WITHBLOCK | back to summary |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| CALLSUPER | back to summary |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| CALLSUPER_WITHBLOCK | back to summary |
|---|---|
| public static final EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| MethodType | back to summary |
|---|---|
| private MethodType() | |
| valueOf | back to summary |
|---|---|
| public static EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |
| values | back to summary |
|---|---|
| public static EmbedRubyObjectAdapterImpl. References Deprecated
See corresponding docs for further information. | |