public interface EmbedRubyInstanceConfigAdapter
Modifier and Type | Method and Description |
---|---|
java.lang.String[] |
getArgv()
Returns an arguments' list.
|
java.lang.ClassLoader |
getClassLoader()
Returns a class loader object that is currently used.
|
CompatVersion |
getCompatVersion()
Deprecated.
|
RubyInstanceConfig.CompileMode |
getCompileMode()
Returns a compile mode currently chosen, which is one of CompileMode.JIT,
CompileMode.FORCE, CompileMode.OFF.
|
java.lang.String |
getCurrentDirectory()
Returns a current directory.
|
java.util.Map |
getEnvironment()
Returns a map of environment variables.
|
java.io.PrintStream |
getError()
Returns an error stream assigned to STDERR and $stderr.
|
java.lang.String |
getHomeDirectory()
Returns a JRuby home directory.
|
java.io.InputStream |
getInput()
Returns an input stream assigned to STDIN and $stdin.
|
int |
getJitLogEvery()
Returns the value of n, which means that jitted methods are logged in
every n methods.
|
int |
getJitMax()
Returns a value of a max class cache size.
|
int |
getJitMaxSize()
Returns a value of a max size of the bytecode generated by compiler.
|
int |
getJitThreshold()
Returns a value of the threshold that determines whether jitted methods'
call reached to the limit or not.
|
KCode |
getKCode()
Returns a value of KCode currently used.
|
java.util.List<java.lang.String> |
getLoadPaths()
Returns a list of load paths for Ruby scripts/libraries.
|
RubyInstanceConfig.LoadServiceCreator |
getLoadServiceCreator()
Returns a LoadServiceCreator currently used.
|
java.io.PrintStream |
getOutput()
Returns an output stream assigned to STDOUT and $stdout
|
Profile |
getProfile()
Returns a profiler currently used.
|
java.lang.String |
getRecordSeparator()
Returns a record separator.
|
java.lang.String |
getScriptFilename()
Returns a script filename to run.
|
java.lang.String |
getSupportedRubyVersion()
Returns version information about JRuby and Ruby supported by this platform.
|
boolean |
isObjectSpaceEnabled()
Tests whether the Object Space is enabled or not.
|
boolean |
isRunRubyInProcess()
Tests whether Ruby runs in a process or not.
|
void |
setArgv(java.lang.String[] argv)
Changes values of the arguments' list.
|
void |
setClassLoader(java.lang.ClassLoader loader)
Changes a class loader to a given loader.
|
void |
setCompatVersion(CompatVersion version)
Deprecated.
|
void |
setCompileMode(RubyInstanceConfig.CompileMode mode)
Changes a compile mode to a given mode, which should be one of CompileMode.JIT,
CompileMode.FORCE, CompileMode.OFF.
|
void |
setCurrentDirectory(java.lang.String directory)
Changes a current directory to a given directory.
|
void |
setEnvironment(java.util.Map environment)
Changes an environment variables' map.
|
void |
setError(java.io.PrintStream pstream)
Changes STDERR and $stderr to a gievn print stream.
|
void |
setError(java.io.Writer writer)
Changes STDERR and $stderr to a given writer.
|
void |
setHomeDirectory(java.lang.String home)
Changes a JRuby home directroy to a directory of a given name.
|
void |
setInput(java.io.InputStream istream)
Changes STDIN and $stdin to a given input stream.
|
void |
setInput(java.io.Reader reader)
Changes STDIN and $stdin to a given reader.
|
void |
setJitLogEvery(int logEvery)
Changes a value of n, so that jitted methods are logged in every n methods.
|
void |
setJitMax(int max)
Changes a value of a max class cache size.
|
void |
setJitMaxSize(int maxSize)
Changes a value of a max size of the bytecode generated by compiler.
|
void |
setJitThreshold(int threshold)
Changes a value of the threshold that determines whether jitted methods'
call reached to the limit or not.
|
void |
setKCode(KCode kcode)
Changes a value of KCode to a given value.
|
void |
setLoadPaths(java.util.List<java.lang.String> paths)
Changes a list of load paths Ruby scripts/libraries.
|
void |
setLoadServiceCreator(RubyInstanceConfig.LoadServiceCreator creator)
Changes a LoadServiceCreator to a given one.
|
void |
setObjectSpaceEnabled(boolean enable)
Changes the value to determine whether the Object Space is enabled or not.
|
void |
setOutput(java.io.PrintStream pstream)
Changes STDOUT and $stdout to a given output stream.
|
void |
setOutput(java.io.Writer writer)
Changes STDOUT and $stdout to a given writer.
|
void |
setProfile(Profile profile)
Changes a profiler to a given one.
|
void |
setRecordSeparator(java.lang.String separator)
Changes a record separator to a given value.
|
void |
setRunRubyInProcess(boolean inprocess)
Changes the value to determine whether Ruby runs in a process or not.
|
void |
setScriptFilename(java.lang.String filename)
Changes a script filename to run.
|
java.util.List<java.lang.String> getLoadPaths()
void setLoadPaths(java.util.List<java.lang.String> paths)
paths
- a new list of load paths.java.io.InputStream getInput()
void setInput(java.io.InputStream istream)
istream
- an input stream to be setvoid setInput(java.io.Reader reader)
reader
- a reader to be setjava.io.PrintStream getOutput()
void setOutput(java.io.PrintStream pstream)
pstream
- an output stream to be setvoid setOutput(java.io.Writer writer)
writer
- a writer to be setjava.io.PrintStream getError()
void setError(java.io.PrintStream pstream)
pstream
- a print stream to be setvoid setError(java.io.Writer writer)
writer
- a writer to be setRubyInstanceConfig.CompileMode getCompileMode()
void setCompileMode(RubyInstanceConfig.CompileMode mode)
mode
- compile modeboolean isRunRubyInProcess()
void setRunRubyInProcess(boolean inprocess)
inprocess
- true when Ruby is set to run in the process, or false not to
run in the process.boolean isObjectSpaceEnabled()
void setObjectSpaceEnabled(boolean enable)
enable
- true to enable the Object Space, or false to disable.java.util.Map getEnvironment()
void setEnvironment(java.util.Map environment)
environment
- a new map of environment variables.java.lang.String getCurrentDirectory()
void setCurrentDirectory(java.lang.String directory)
directory
- a new directory to be set.java.lang.String getHomeDirectory()
void setHomeDirectory(java.lang.String home)
home
- a name of new JRuby home directory.java.lang.ClassLoader getClassLoader()
void setClassLoader(java.lang.ClassLoader loader)
loader
- a new class loader to be set.Profile getProfile()
void setProfile(Profile profile)
profile
- a new profiler to be set.RubyInstanceConfig.LoadServiceCreator getLoadServiceCreator()
void setLoadServiceCreator(RubyInstanceConfig.LoadServiceCreator creator)
creator
- a new LoadServiceCreatorjava.lang.String[] getArgv()
void setArgv(java.lang.String[] argv)
argv
- a new arguments' list.java.lang.String getScriptFilename()
void setScriptFilename(java.lang.String filename)
filename
- a new script filename.java.lang.String getRecordSeparator()
void setRecordSeparator(java.lang.String separator)
separator
- a new record separator value, "0" or "777"KCode getKCode()
void setKCode(KCode kcode)
kcode
- a new KCode value.int getJitLogEvery()
void setJitLogEvery(int logEvery)
logEvery
- a new number of methods.int getJitThreshold()
void setJitThreshold(int threshold)
threshold
- a new value of the threshold.int getJitMax()
void setJitMax(int max)
max
- a new value of a max class cache size.int getJitMaxSize()
void setJitMaxSize(int maxSize)
maxSize
- a new value of a max size of the bytecode.java.lang.String getSupportedRubyVersion()
@Deprecated CompatVersion getCompatVersion()
@Deprecated void setCompatVersion(CompatVersion version)
Copyright © 2001-2019 JRuby. All Rights Reserved.