API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.script. SimpleScriptContext View Source
Author(s)
Mike Grogan
Since
1.6
Version
1.0
Serial
Hierarchy
 Object
      SimpleScriptContext
Implements
 ScriptContext
Subclasses
Description
public class SimpleScriptContext
  Simple implementation of ScriptContext.
See also:   
Constructors
public SimpleScriptContext ()
Methods
Hide/Show inherited methods
public Object getAttribute (String name) [Specified in ScriptContext]
  Retrieves the value of the attribute with the given name in the scope occurring earliest in the search order.
public Object getAttribute (String name, int scope) [Specified in ScriptContext]
  Gets the value of an attribute in a given scope.
public int getAttributesScope (String name) [Specified in ScriptContext]
  Get the lowest scope in which an attribute is defined.
public Bindings getBindings (int scope) [Specified in ScriptContext]
  Returns the value of the engineScope field if specified scope is ENGINE_SCOPE.
public Writer getErrorWriter () [Specified in ScriptContext]
Returns the Writer used to display error output.
public Reader getReader () [Specified in ScriptContext]
Returns a Reader to be used by the script to read input.
public List<Integer> getScopes () [Specified in ScriptContext]
Returns immutable List of all the valid values for scope in the ScriptContext.
public Writer getWriter () [Specified in ScriptContext]
Returns the Writer for scripts to use when displaying output.
public Object removeAttribute (String name, int scope) [Specified in ScriptContext]
  Remove an attribute in a given scope.
public void setAttribute (String name, Object value, int scope) [Specified in ScriptContext]
  Sets the value of an attribute in a given scope.
public void setBindings (Bindings bindings, int scope) [Specified in ScriptContext]
  Sets a Bindings of attributes for the given scope.
public void setErrorWriter (Writer writer) [Specified in ScriptContext]
Sets the Writer used to display error output.
public void setReader (Reader reader) [Specified in ScriptContext]
Sets the Reader for scripts to read input .
public void setWriter (Writer writer) [Specified in ScriptContext]
Sets the Writer for scripts to use when displaying output.
Fields
Hide/Show inherited fields
publicfinalstatic int ENGINE_SCOPE = "100" [Inherited From ScriptContext]
EngineScope attributes are visible during the lifetime of a single ScriptEngine and a set of attributes is maintained for each engine.
protected Bindings engineScope
  This is the engine scope bindings.
protected Writer errorWriter
  This is the writer to be used to output errors from scripts.
publicfinalstatic int GLOBAL_SCOPE = "200" [Inherited From ScriptContext]
GlobalScope attributes are visible to all engines created by same ScriptEngineFactory.
protected Bindings globalScope
  This is the global scope bindings.
protected Reader reader
  This is the reader to be used for input from scripts.
protected Writer writer
  This is the writer to be used to output from scripts.
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar