Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
org.mozilla.javascript.ScriptableObject
org.mozilla.javascript.IdScriptableObject
org.mozilla.javascript.NativeArray
public class NativeArray
extends IdScriptableObject
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 | |
void |
|
Object |
|
protected int |
|
protected int |
|
Object |
|
String | |
Object |
|
Object[] |
|
protected String |
|
protected Object |
|
long | |
protected int |
|
boolean |
|
protected void |
|
long |
|
void |
|
void |
|
protected 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 void delete(int index)
- Specified by:
- delete in interface Scriptable
- Overrides:
- delete in interface ScriptableObject
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 findInstanceIdInfo(String s)
Map name to id of instance property. Should return 0 if not found or the result ofIdScriptableObject.instanceIdInfo(int,int)
.
- Overrides:
- findInstanceIdInfo in interface IdScriptableObject
protected int findPrototypeId(String s)
- Overrides:
- findPrototypeId in interface IdScriptableObject
public Object get(int index, Scriptable start)
- Specified by:
- get in interface Scriptable
- Overrides:
- get in interface ScriptableObject
public String getClassName()
- Specified by:
- getClassName in interface Scriptable
- Overrides:
- getClassName in interface ScriptableObject
public Object getDefaultValue(Class hint)
- Specified by:
- getDefaultValue in interface Scriptable
- Overrides:
- getDefaultValue in interface ScriptableObject
public Object[] getIds()
- Specified by:
- getIds in interface Scriptable
- Overrides:
- getIds in interface ScriptableObject
protected String getInstanceIdName(int id)
Map id back to property name it defines.
- Overrides:
- getInstanceIdName in interface IdScriptableObject
protected Object getInstanceIdValue(int id)
Get id value. If id value is constant, descendant can call cacheIdValue to store value in the permanent cache. Default implementation creates IdFunctionObject instance for given id and cache its value
- Overrides:
- getInstanceIdValue in interface IdScriptableObject
public long getLength()
protected int getMaxInstanceId()
Get maximum id findInstanceIdInfo can generate.
- Overrides:
- getMaxInstanceId in interface IdScriptableObject
public boolean has(int index, Scriptable start)
- Specified by:
- has in interface Scriptable
- Overrides:
- has in interface ScriptableObject
protected void initPrototypeId(int id)
- Overrides:
- initPrototypeId in interface IdScriptableObject
public void put(String id, Scriptable start, Object value)
- Specified by:
- put in interface Scriptable
- Overrides:
- put in interface IdScriptableObject
public void put(int index, Scriptable start, Object value)
- Specified by:
- put in interface Scriptable
- Overrides:
- put in interface ScriptableObject
protected void setInstanceIdValue(int id, Object value)
Set or delete id value. If value == NOT_FOUND , the implementation should make sure that the following getInstanceIdValue return NOT_FOUND.
- Overrides:
- setInstanceIdValue in interface IdScriptableObject