org.mozilla.javascript

Class NativeArray

Implemented Interfaces:
ConstProperties, DebuggableObject, IdFunctionCall, Scriptable, Serializable

public class NativeArray
extends IdScriptableObject

This class implements the Array native object.
Authors:
Norris Boyd
Mike McCabe

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

NativeArray(Object[] array)
NativeArray(long lengthArg)

Method Summary

@Override
Object execIdCall(IdFunctionObject f, Context cx, Scriptable scope, Scriptable thisObj, Object[] args)
@Override
Object get(int index, Scriptable start)
@Override
Object getDefaultValue(Class hint)
protected @Override
Object getInstanceIdValue(int id)
@Override
Object[] getIds()
@Override
String getClassName()
protected @Override
String getInstanceIdName(int id)
@Override
boolean has(int index, Scriptable start)
long
getLength()
protected @Override
int findInstanceIdInfo(String s)
protected @Override
int findPrototypeId(String s)
protected @Override
int getMaxInstanceId()
long
jsGet_length()
Deprecated. Use getLength() instead.
@Override
void delete(int index)
protected @Override
void fillConstructorProperties(IdFunctionObject ctor)
protected @Override
void initPrototypeId(int id)
@Override
void put(String id, Scriptable start, Object value)
@Override
void put(int index, Scriptable start, Object value)
protected @Override
void setInstanceIdValue(int id, Object value)

Methods inherited from class org.mozilla.javascript.IdScriptableObject

Object get, activatePrototypeMap, addIdFunctionProperty, boolean has, defaultGet, defaultPut, execIdCall, exportAsJSClass, fillConstructorProperties, findInstanceIdInfo, findPrototypeId, getInstanceIdName, getInstanceIdValue, getMaxInstanceId, hasPrototypeMap, incompatibleCallError, initPrototypeConstructor, initPrototypeId, initPrototypeMethod, initPrototypeValue, instanceIdInfo, int getAttributes, setInstanceIdValue, void delete, void put, void setAttributes

Methods inherited from class org.mozilla.javascript.ScriptableObject

associateValue, avoidObjectDetection, callMethod, callMethod, defineConst, defineConstProperty, defineFunctionProperties, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, equivalentValues, extends Scriptable> String defineClass, extends Scriptable> void defineClass, extends Scriptable> void defineClass, get, get, getAllIds, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassName, getClassPrototype, getDefaultValue, getDefaultValue, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getTopLevelScope, getTopScopeValue, has, has, hasInstance, hasProperty, hasProperty, isConst, isGetterOrSetter, isSealed, put, put, putConst, putConstProperty, putProperty, putProperty, redefineProperty, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setGetterOrSetter, setParentScope, setPrototype

Constructor Details

NativeArray

public NativeArray(Object[] array)

NativeArray

public NativeArray(long lengthArg)

Method Details

Object execIdCall

public @Override Object execIdCall(IdFunctionObject f,
                                   Context cx,
                                   Scriptable scope,
                                   Scriptable thisObj,
                                   Object[] args)

Object get

public @Override Object get(int index,
                            Scriptable start)

Object getDefaultValue

public @Override Object getDefaultValue(Class hint)

Object getInstanceIdValue

protected @Override Object getInstanceIdValue(int id)

Object[] getIds

public @Override Object[] getIds()

String getClassName

public @Override String getClassName()

String getInstanceIdName

protected @Override String getInstanceIdName(int id)

boolean has

public @Override boolean has(int index,
                             Scriptable start)

getLength

public long getLength()

int findInstanceIdInfo

protected @Override int findInstanceIdInfo(String s)

int findPrototypeId

protected @Override int findPrototypeId(String s)

int getMaxInstanceId

protected @Override int getMaxInstanceId()

jsGet_length

public long jsGet_length()

Deprecated. Use getLength() instead.


void delete

public @Override void delete(int index)

void fillConstructorProperties

protected @Override void fillConstructorProperties(IdFunctionObject ctor)

void initPrototypeId

protected @Override void initPrototypeId(int id)

void put

public @Override void put(String id,
                          Scriptable start,
                          Object value)
Overrides:
void put in interface IdScriptableObject

void put

public @Override void put(int index,
                          Scriptable start,
                          Object value)

void setInstanceIdValue

protected @Override void setInstanceIdValue(int id,
                                            Object value)