Class NativeInt8Array
java.lang.Object
org.mozilla.javascript.ScriptableObject
org.mozilla.javascript.IdScriptableObject
org.mozilla.javascript.typedarrays.NativeArrayBufferView
org.mozilla.javascript.typedarrays.NativeTypedArrayView<Byte>
org.mozilla.javascript.typedarrays.NativeInt8Array
- All Implemented Interfaces:
Serializable,Iterable<Byte>,Collection<Byte>,List<Byte>,RandomAccess,SequencedCollection<Byte>,ConstProperties,DebuggableObject,ExternalArrayData,IdFunctionCall,Scriptable,SymbolScriptable
An array view that stores 8-bit quantities and implements the JavaScript "Int8Array" interface.
It also implements List<Byte> for direct manipulation in Java.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.mozilla.javascript.ScriptableObject
ScriptableObject.KeyComparator -
Field Summary
FieldsFields inherited from class org.mozilla.javascript.typedarrays.NativeTypedArrayView
length, MAX_PROTOTYPE_IDFields inherited from class org.mozilla.javascript.typedarrays.NativeArrayBufferView
arrayBuffer, byteLength, offsetFields inherited from class org.mozilla.javascript.ScriptableObject
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONSTFields inherited from interface org.mozilla.javascript.Scriptable
NOT_FOUND -
Constructor Summary
ConstructorsConstructorDescriptionNativeInt8Array(int len) NativeInt8Array(NativeArrayBuffer ab, int off, int len) -
Method Summary
Modifier and TypeMethodDescriptionprotected NativeInt8Arrayconstruct(NativeArrayBuffer ab, int off, int len) get(int i) intReturn the number of bytes represented by each element in the array.Return the name of the class.static voidinit(Context cx, Scriptable scope, boolean sealed) protected Objectjs_get(int index) protected Objectprotected NativeInt8ArrayrealThis(Scriptable thisObj, IdFunctionObject f) Methods inherited from class org.mozilla.javascript.typedarrays.NativeTypedArrayView
add, add, addAll, addAll, checkIndex, clear, contains, containsAll, delete, equals, execIdCall, fillConstructorProperties, findInstanceIdInfo, findPrototypeId, findPrototypeId, get, getArrayElement, getArrayLength, getIds, getInstanceIdName, getInstanceIdValue, getMaxInstanceId, has, hashCode, indexOf, initPrototypeId, isEmpty, iterator, lastIndexOf, listIterator, listIterator, put, remove, remove, removeAll, retainAll, setArrayElement, size, subList, toArray, toArrayMethods inherited from class org.mozilla.javascript.typedarrays.NativeArrayBufferView
getBuffer, getByteLength, getByteOffset, isArg, useLittleEndianMethods inherited from class org.mozilla.javascript.IdScriptableObject
activatePrototypeMap, addIdFunctionProperty, defaultGet, defaultHas, defaultPut, defineOwnProperty, delete, delete, ensureType, exportAsJSClass, findInstanceIdInfo, get, get, getAttributes, getAttributes, getOwnPropertyDescriptor, has, has, hasPrototypeMap, initPrototypeConstructor, initPrototypeMethod, initPrototypeMethod, initPrototypeMethod, initPrototypeValue, initPrototypeValue, instanceIdInfo, put, put, setAttributes, setInstanceIdAttributes, setInstanceIdValueMethods inherited from class org.mozilla.javascript.ScriptableObject
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChange, checkPropertyDefinition, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineOwnProperties, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, ensureSymbolScriptable, equivalentValues, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGeneratorFunctionPrototype, getGetterOrSetter, getGetterOrSetter, getObjectPrototype, getParentScope, getProperty, getProperty, getProperty, getPropertyIds, getPrototype, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, hasInstance, hasProperty, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, putConst, putConstProperty, putProperty, putProperty, putProperty, querySlot, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setCommonDescriptorProperties, setExternalArrayData, setGetterOrSetter, setParentScope, setPrototypeMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
addFirst, addLast, getFirst, getLast, removeFirst, removeLast, replaceAll, reversed, sort, spliterator
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
CLASS_NAME
- See Also:
-
-
Constructor Details
-
NativeInt8Array
public NativeInt8Array() -
NativeInt8Array
-
NativeInt8Array
public NativeInt8Array(int len)
-
-
Method Details
-
getClassName
Description copied from class:ScriptableObjectReturn the name of the class.This is typically the same name as the constructor. Classes extending ScriptableObject must implement this abstract method.
- Specified by:
getClassNamein interfaceScriptable- Specified by:
getClassNamein classScriptableObject
-
init
-
construct
- Specified by:
constructin classNativeTypedArrayView<Byte>
-
getBytesPerElement
public int getBytesPerElement()Description copied from class:NativeTypedArrayViewReturn the number of bytes represented by each element in the array. This can be useful when wishing to manipulate the byte array directly from Java.- Specified by:
getBytesPerElementin classNativeTypedArrayView<Byte>
-
realThis
- Specified by:
realThisin classNativeTypedArrayView<Byte>
-
js_get
- Specified by:
js_getin classNativeTypedArrayView<Byte>
-
js_set
- Specified by:
js_setin classNativeTypedArrayView<Byte>
-
get
-
set
-