Evaluate an arbitrary Ruby expression, casting and wrapping the return value
Evaluate an arbitrary Ruby expression, casting and wrapping the return value
The expected class of the return value
The ruby expression to evaluate
The expression's return value.
wrap
org.jruby.embed.ScriptingContainer#runScriptlet
Evaluate an arbitrary Ruby expression, ignoring the return value
Evaluate an arbitrary Ruby expression, ignoring the return value
The ruby expression to evaluate
The expression's return value. If it's an org.jruby.RubyObj it's wrapped in a com.tecnoguru.scuby.RubyObj, otherwise it's returned as-is.
wrap
org.jruby.embed.ScriptingContainer#runScriptlet
Evaluate an arbitrary Ruby expression, expecting to get back a RubyObj
Evaluate an arbitrary Ruby expression, expecting to get back a RubyObj
The ruby expression to evaluate
The expression's return value. If it's an org.jruby.RubyObj it's wrapped in a com.tecnoguru.scuby.RubyObj, otherwise it's returned as-is.
wrap
org.jruby.embed.ScriptingContainer#runScriptlet
Load a Ruby file from the CLASSPATH into the JRuby environment
Load a Ruby file from the CLASSPATH into the JRuby environment
The file name to load, relative to the CLASSPATH
Returns the underlying Ruby runtime
Returns the underlying Ruby runtime
The underlying Ruby runtime
This trait is one of the main entry points into Scuby. Including it allows you to evaluate arbitrary Ruby code, invoke JRuby functions and require Ruby files contained in the CLASSPATH. The other entry points are RubyClass and RubyObj. The JRuby object is also provided to give the option of extending the trait or including the object.
JRuby
RubyObj
RubyClass