| Package | Description |
|---|---|
| bsh |
| Modifier and Type | Class and Description |
|---|---|
class |
ExternalNameSpace
A namespace which maintains an external map of values held in variables in
its scope.
|
| Modifier and Type | Field and Description |
|---|---|
static NameSpace |
NameSpace.JAVACODE
The Constant JAVACODE.
|
| Modifier and Type | Field and Description |
|---|---|
static java.util.Map<java.lang.String,NameSpace> |
This.contextStore |
| Modifier and Type | Method and Description |
|---|---|
NameSpace |
CallStack.get(int depth)
zero based.
|
NameSpace |
Interpreter.getNameSpace()
Retrieve the global namespace for this interpreter.
|
NameSpace |
This.getNameSpace() |
NameSpace |
NameSpace.getParent()
Get the parent namespace.
|
static NameSpace |
Reflect.getThisNS(java.lang.Class<?> type) |
static NameSpace |
Reflect.getThisNS(java.lang.Object object) |
NameSpace |
CallStack.pop() |
NameSpace |
CallStack.swap(NameSpace newTop)
Swap in the value as the new top of the stack and return the old
value.
|
NameSpace |
CallStack.top() |
| Modifier and Type | Method and Description |
|---|---|
static void |
This.bind(This ths,
NameSpace namespace,
Interpreter declaringInterpreter)
Bind a This reference to a parent's namespace with the specified
declaring interpreter.
|
java.lang.Object |
Interpreter.eval(java.io.Reader in,
NameSpace nameSpace,
java.lang.String sourceFileInfo)
Spawn a non-interactive local interpreter to evaluate text in the
specified namespace.
|
java.lang.Object |
Interpreter.eval(java.lang.String statements,
NameSpace nameSpace)
Evaluate the string in the specified namespace.
|
static BshMethod |
Reflect.getMethod(NameSpace ns,
java.lang.String name,
java.lang.Class<?>[] sig) |
static BshMethod |
Reflect.getMethod(NameSpace ns,
java.lang.String name,
java.lang.Class<?>[] sig,
boolean declaredOnly) |
static java.lang.String[] |
Reflect.getMethodNames(NameSpace ns) |
static BshMethod[] |
Reflect.getMethods(NameSpace ns) |
static Variable |
Reflect.getVariable(NameSpace ns,
java.lang.String name) |
static java.lang.String[] |
Reflect.getVariableNames(NameSpace ns) |
static Variable[] |
Reflect.getVariables(NameSpace ns) |
static Variable[] |
Reflect.getVariables(NameSpace ns,
java.lang.String[] names) |
void |
ClassGeneratorUtil.initStaticNameSpace(NameSpace classStaticNameSpace,
bsh.BSHBlock instanceInitBlock)
This method provides a hook for the class generator implementation to
store additional information in the class's bsh static namespace.
|
boolean |
NameSpace.isChildOf(NameSpace parent)
Check if this namespace is a child of the given namespace.
|
void |
CallStack.push(NameSpace ns) |
void |
CallStack.set(int depth,
NameSpace ns)
This is kind of crazy, but used by the setNameSpace command.
|
void |
Interpreter.setNameSpace(NameSpace namespace)
Assign the global namespace for this interpreter.
|
void |
NameSpace.setParent(NameSpace parent)
Sets the parent.
|
java.lang.Object |
Interpreter.source(java.io.File file,
NameSpace namespace)
Source a script from a file for interpretation.
|
java.lang.Object |
Interpreter.source(java.lang.String filename,
NameSpace namespace)
Source a script from a filename for interpretation.
|
java.lang.Object |
Interpreter.source(java.net.URL url,
NameSpace namespace)
Source a script from a url for interpretation.
|
NameSpace |
CallStack.swap(NameSpace newTop)
Swap in the value as the new top of the stack and return the old
value.
|
| Constructor and Description |
|---|
CallStack(NameSpace namespace) |
ClassGeneratorUtil(Modifiers classModifiers,
java.lang.String className,
java.lang.String packageName,
java.lang.Class<?> superClass,
java.lang.Class<?>[] interfaces,
Variable[] vars,
DelayedEvalBshMethod[] bshmethods,
NameSpace classStaticNameSpace,
bsh.ClassGenerator.Type type) |
ExternalNameSpace(NameSpace parent,
java.lang.String name,
java.util.Map<java.lang.String,java.lang.Object> externalMap) |
Interpreter(ConsoleAssignable console,
boolean interactive,
NameSpace namespace,
Interpreter parent,
java.lang.String sourceFileInfo)
The main constructor, all other constructors should pass through here.
|
Interpreter(ConsoleInterface console,
NameSpace globalNameSpace)
An interactive interpreter attached to a console with supplied namespace.
|
Interpreter(ConsoleInterface console,
NameSpace namespace,
Interpreter parent)
An interactive interpreter attached to the specified console.
|
Interpreter(NameSpace namespace)
A non interactive interpreter for namespace.
|
Interpreter(NameSpace namespace,
Interpreter parent)
A non interactive interpreter for namespace and parent.
|
Interpreter(NameSpace namespace,
Interpreter parent,
java.lang.String sourceFileInfo)
A non interactive interpreter for namespace, parent and source file.
|
Interpreter(NameSpace namespace,
java.lang.String sourceFileInfo)
A non interactive interpreter for namespace and source file.
|
Interpreter(java.io.Reader in,
java.io.PrintStream out,
java.io.PrintStream err,
boolean interactive,
NameSpace namespace)
Interpreter instance without a parent interpreter and source file.
|
Interpreter(java.io.Reader in,
java.io.PrintStream out,
java.io.PrintStream err,
boolean interactive,
NameSpace namespace,
Interpreter parent,
java.lang.String sourceFileInfo)
Wraps individual input output streams as a console collection.
|
NameSpace(NameSpace parent,
BshClassManager classManager,
java.lang.String name)
Instantiates a new name space.
|
NameSpace(NameSpace parent,
java.lang.String name)
Instantiates a new name space.
|