public class Interpreter extends IRTranslator<IRubyObject,IRubyObject>
| Constructor and Description |
|---|
Interpreter() |
| Modifier and Type | Method and Description |
|---|---|
static void |
dumpStats() |
static IRubyObject |
evalSimple(ThreadContext context,
RubyModule under,
IRubyObject self,
RubyString src,
String file,
int lineNumber,
EvalType evalType)
Evaluate the given string.
|
static IRubyObject |
evalWithBinding(ThreadContext context,
IRubyObject self,
IRubyObject src,
Binding binding)
Evaluate the given string under the specified binding object.
|
protected IRubyObject |
execute(Ruby runtime,
IRScriptBody irScope,
IRubyObject self) |
static IRubyObject |
INTERPRET_BLOCK(ThreadContext context,
Block block,
IRubyObject self,
InterpreterContext ic,
IRubyObject[] args,
String name,
Block blockArg) |
static IRubyObject |
INTERPRET_EVAL(ThreadContext context,
IRubyObject self,
InterpreterContext ic,
RubyModule clazz,
IRubyObject[] args,
String name,
Block blockArg) |
static IRubyObject |
INTERPRET_ROOT(ThreadContext context,
IRubyObject self,
InterpreterContext ic,
RubyModule clazz,
String name) |
static void |
runBeginBlocks(List<IRClosure> beBlocks,
ThreadContext context,
IRubyObject self,
StaticScope currScope,
Object[] temp) |
executepublic static final Logger LOG
public static final String ROOT
public static void dumpStats()
public static void runBeginBlocks(List<IRClosure> beBlocks, ThreadContext context, IRubyObject self, StaticScope currScope, Object[] temp)
protected IRubyObject execute(Ruby runtime, IRScriptBody irScope, IRubyObject self)
execute in class IRTranslator<IRubyObject,IRubyObject>public static IRubyObject INTERPRET_ROOT(ThreadContext context, IRubyObject self, InterpreterContext ic, RubyModule clazz, String name)
public static IRubyObject INTERPRET_EVAL(ThreadContext context, IRubyObject self, InterpreterContext ic, RubyModule clazz, IRubyObject[] args, String name, Block blockArg)
public static IRubyObject INTERPRET_BLOCK(ThreadContext context, Block block, IRubyObject self, InterpreterContext ic, IRubyObject[] args, String name, Block blockArg)
public static IRubyObject evalSimple(ThreadContext context, RubyModule under, IRubyObject self, RubyString src, String file, int lineNumber, EvalType evalType)
context - the current thread's contextself - the self to evaluate undersrc - The string containing the text to be evaluatedfile - The filename to use when reporting errors during the evaluationlineNumber - that the eval supposedly starts frompublic static IRubyObject evalWithBinding(ThreadContext context, IRubyObject self, IRubyObject src, Binding binding)
context - the thread context for the current threadself - the self against which eval was called; used as self in the eval in 1.9 modesrc - The string containing the text to be evaluatedbinding - The binding object under which to perform the evaluationCopyright © 2001-2016 JRuby. All Rights Reserved.