org.apache.bsf.engines.javascript

Class JsContextStub

Implemented Interfaces:
JsContext, Remote

public class JsContextStub
extends Skeleton
implements JsContext

Insert the type's description here. Creation date: (8/23/2001 4:16:50 PM)

Constructor Summary

JsContextStub(RhinoContextProxy rcp, DebugFrame frame, int frameno)
JsContextStub constructor comment.

Method Summary

JsObject
bind(String id)
JsCode
getCode()
int
getDepth()
JsEngine
getEngine()
int
getLineNumber()
JsObject
getScope()
Scope of a context.
String
getSourceName()
JsObject
getThis()
boolean
isEvalContext()
boolean
isFunctionContext()
boolean
isScriptContext()
Object
lookupName(Scriptable scopeChain, String id)
Looks up a name in the scope chain and returns its value.
Object
lookupName(String name)

Methods inherited from class org.apache.bsf.debug.util.Skeleton

addListener, allocOid, completeFuture, createFuture, equals, getTid, getUid, hasNoUid, removeListener, suspendFuture

Constructor Details

JsContextStub

public JsContextStub(RhinoContextProxy rcp,
                     DebugFrame frame,
                     int frameno)
            throws RemoteException
JsContextStub constructor comment.

Method Details

bind

public JsObject bind(String id)
            throws RemoteException
Specified by:
bind in interface JsContext


getCode

public JsCode getCode()
Specified by:
getCode in interface JsContext


getDepth

public int getDepth()
Specified by:
getDepth in interface JsContext


getEngine

public JsEngine getEngine()
Specified by:
getEngine in interface JsContext


getLineNumber

public int getLineNumber()
Specified by:
getLineNumber in interface JsContext


getScope

public JsObject getScope()
            throws RemoteException
Scope of a context. See ECMA 262, 3rd edition, 10.1.6 through 10.1.8 The scope depends on if the context represents global code, eval code, or function code. Global Code: The scope chain is cerated and initialised to contain the global objects and no others. Eval Code: The scope chain is initialized to contains the same scope chain as the calling context. This includes the same activation object and therefore the same arguments and local variables. Function Code: The scope chain is initialised to contain the activation object followed by the objects in the scope chain stored in the [[Scope]] property of the Function object.
Specified by:
getScope in interface JsContext


getSourceName

public String getSourceName()
Specified by:
getSourceName in interface JsContext


getThis

public JsObject getThis()
            throws RemoteException
Specified by:
getThis in interface JsContext


isEvalContext

public boolean isEvalContext()


isFunctionContext

public boolean isFunctionContext()


isScriptContext

public boolean isScriptContext()


lookupName

public Object lookupName(Scriptable scopeChain,
                         String id)
Looks up a name in the scope chain and returns its value.


lookupName

public Object lookupName(String name)