| Prev Class | Next Class | Frames | No Frames |
| Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Objectorg.mozilla.javascript.ScriptableObjectorg.mozilla.javascript.IdScriptableObjectorg.mozilla.javascript.ImporterTopLevelpublic class ImporterTopLevelextends IdScriptableObjectScriptable scope = new ImporterTopLevel(cx);Then JavaScript code will have access to the following methods:
js> importClass(java.io.File)
js> f = new File('help.txt')
help.txt
js> importPackage(java.util)
js> v = new Vector()
[]
Field Summary |
Fields inherited from class org.mozilla.javascript.ScriptableObject | |
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONST | |
Fields inherited from interface org.mozilla.javascript.Scriptable | |
NOT_FOUND | |
Constructor Summary | |
| |
Method Summary | |
Object |
|
protected int |
|
Object |
|
String | |
boolean |
|
void |
|
static void |
|
protected void |
|
void |
|
Methods inherited from class org.mozilla.javascript.IdScriptableObject | |
activatePrototypeMap, addIdFunctionProperty, defaultGet, defaultPut, delete, execIdCall, exportAsJSClass, fillConstructorProperties, findInstanceIdInfo, findPrototypeId, get, getAttributes, getInstanceIdName, getInstanceIdValue, getMaxInstanceId, has, hasPrototypeMap, incompatibleCallError, initPrototypeConstructor, initPrototypeId, initPrototypeMethod, initPrototypeValue, instanceIdInfo, put, setAttributes, setInstanceIdValue | |
public Object execIdCall(IdFunctionObject f, Context cx, Scriptable scope, Scriptable thisObj, Object[] args)
'thisObj' will be null if invoked as constructor, in which case instance of Scriptable should be returned.
- Specified by:
- execIdCall in interface IdFunctionCall
- Overrides:
- execIdCall in interface IdScriptableObject
protected int findPrototypeId(String s)
- Overrides:
- findPrototypeId in interface IdScriptableObject
public Object get(String name,
Scriptable start)
- Specified by:
- get in interface Scriptable
- Overrides:
- get in interface IdScriptableObject
public String getClassName()
- Specified by:
- getClassName in interface Scriptable
- Overrides:
- getClassName in interface ScriptableObject
public boolean has(String name,
Scriptable start)
- Specified by:
- has in interface Scriptable
- Overrides:
- has in interface IdScriptableObject
public void importPackage(Context cx, Scriptable thisObj, Object[] args, Function funObj)
Deprecated. Kept only for compatibility.
protected void initPrototypeId(int id)
- Overrides:
- initPrototypeId in interface IdScriptableObject