org.mentawai.jruby
Class JRubyInterpreter

java.lang.Object
  extended by org.mentawai.jruby.JRubyInterpreter
All Implemented Interfaces:
java.lang.Runnable

public class JRubyInterpreter
extends java.lang.Object
implements java.lang.Runnable


Field Summary
static long RELOAD_INTERVAL
           
 
Method Summary
 java.lang.String callAction(java.lang.Object rubyObject, java.lang.String methodName)
           
 java.lang.Object callGetter(java.lang.Object rubyObject, java.lang.String name)
           
 java.lang.Object callGetter(java.lang.Object rubyObject, java.lang.String name, java.lang.Class<? extends java.lang.Object> returnType)
           
 void callMethod(java.lang.Object rubyObject, java.lang.String methodName)
           
 java.lang.Object callMethod(java.lang.Object rubyObject, java.lang.String methodName, java.lang.Class<? extends java.lang.Object> returnType)
           
 void callMethod(java.lang.Object rubyObject, java.lang.String methodName, java.lang.Object[] params)
           
 java.lang.Object callMethod(java.lang.Object rubyObject, java.lang.String methodName, java.lang.Object[] params, java.lang.Class<? extends java.lang.Object> returnType)
           
 void callSetter(java.lang.Object rubyObject, java.lang.String name, java.lang.Object value)
           
 void close()
           
 java.lang.Object eval(java.lang.String code)
           
static JRubyInterpreter getInstance()
           
 org.jruby.Ruby getRuntime()
           
 java.util.List<java.lang.String> getSetters(java.lang.Object rubyObject)
           
static boolean isInitialized()
           
 void loadFileFromClasspath(java.lang.String filename)
           
 void require(java.lang.String file)
           
 boolean respondTo(java.lang.Object rubyObject, java.lang.String methodName)
           
 void run()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RELOAD_INTERVAL

public static long RELOAD_INTERVAL
Method Detail

run

public void run()
Specified by:
run in interface java.lang.Runnable

close

public void close()

getSetters

public java.util.List<java.lang.String> getSetters(java.lang.Object rubyObject)

require

public void require(java.lang.String file)

eval

public java.lang.Object eval(java.lang.String code)

callAction

public java.lang.String callAction(java.lang.Object rubyObject,
                                   java.lang.String methodName)

callMethod

public java.lang.Object callMethod(java.lang.Object rubyObject,
                                   java.lang.String methodName,
                                   java.lang.Class<? extends java.lang.Object> returnType)

callMethod

public void callMethod(java.lang.Object rubyObject,
                       java.lang.String methodName)

callMethod

public java.lang.Object callMethod(java.lang.Object rubyObject,
                                   java.lang.String methodName,
                                   java.lang.Object[] params,
                                   java.lang.Class<? extends java.lang.Object> returnType)

callMethod

public void callMethod(java.lang.Object rubyObject,
                       java.lang.String methodName,
                       java.lang.Object[] params)

callSetter

public void callSetter(java.lang.Object rubyObject,
                       java.lang.String name,
                       java.lang.Object value)

callGetter

public java.lang.Object callGetter(java.lang.Object rubyObject,
                                   java.lang.String name)

callGetter

public java.lang.Object callGetter(java.lang.Object rubyObject,
                                   java.lang.String name,
                                   java.lang.Class<? extends java.lang.Object> returnType)

respondTo

public boolean respondTo(java.lang.Object rubyObject,
                         java.lang.String methodName)

isInitialized

public static boolean isInitialized()

getInstance

public static JRubyInterpreter getInstance()

loadFileFromClasspath

public void loadFileFromClasspath(java.lang.String filename)
                           throws java.io.IOException
Throws:
java.io.IOException

getRuntime

public org.jruby.Ruby getRuntime()


Copyright © 2005 Mentawai Team. All Rights Reserved.