public class NativeArrayBuffer extends ScriptableObject
ScriptableObject.KeyComparator, ScriptableObject.LambdaGetterFunction, ScriptableObject.LambdaSetterFunction| Modifier and Type | Field and Description |
|---|---|
static String |
CLASS_NAME |
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONSTNOT_FOUND| Constructor and Description |
|---|
NativeArrayBuffer()
Create an empty buffer.
|
NativeArrayBuffer(double len)
Create a buffer of the specified length in bytes.
|
| Modifier and Type | Method and Description |
|---|---|
void |
detach() |
byte[] |
getBuffer()
Return the actual bytes that back the buffer.
|
String |
getClassName()
Return the name of the class.
|
int |
getLength()
Get the number of bytes in the buffer.
|
static Object |
init(Context cx,
Scriptable scope,
boolean sealed) |
boolean |
isDetached() |
NativeArrayBuffer |
slice(double s,
double e)
Return a new buffer that represents a slice of this buffer's content, starting at position
"start" and ending at position "end".
|
applyDescriptorToAttributeBitset, associateValue, avoidObjectDetection, buildDataDescriptor, callMethod, callMethod, checkPropertyChangeForSlot, checkPropertyDefinition, defineBuiltInProperty, defineBuiltInProperty, defineBuiltInProperty, defineBuiltInProperty, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineOwnProperties, defineOwnProperty, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, delete, deleteProperty, deleteProperty, deleteProperty, ensureScriptable, ensureScriptableObject, ensureScriptableObjectButNotSymbol, ensureSymbolScriptable, ensureType, equivalentValues, get, get, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGeneratorFunctionPrototype, getGetterOrSetter, getGetterOrSetter, getIds, getObjectPrototype, getOwnPropertyDescriptor, getParentScope, getProperty, getProperty, getProperty, getPropertyIds, getPrototype, getSuperProperty, getSuperProperty, getSuperProperty, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, has, has, has, hasInstance, hasProperty, hasProperty, hasProperty, isAccessorDescriptor, isConst, isDataDescriptor, isEmpty, isExtensible, isFalse, isGenericDescriptor, isGetterOrSetter, isSealed, isTrue, preventExtensions, put, put, put, putConst, putConstProperty, putOwnProperty, putOwnProperty, putOwnProperty, putProperty, putProperty, putProperty, putSuperProperty, putSuperProperty, putSuperProperty, querySlot, redefineProperty, sameValue, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setAttributes, setCommonDescriptorProperties, setExternalArrayData, setGetterOrSetter, setParentScope, setPrototype, sizecreateSlotMappublic static final String CLASS_NAME
public NativeArrayBuffer()
public NativeArrayBuffer(double len)
public String getClassName()
ScriptableObjectThis is typically the same name as the constructor. Classes extending ScriptableObject must implement this abstract method.
getClassName in interface ScriptablegetClassName in class ScriptableObjectpublic static Object init(Context cx, Scriptable scope, boolean sealed)
public int getLength()
public byte[] getBuffer()
public void detach()
public boolean isDetached()
public NativeArrayBuffer slice(double s, double e)
s - the position where the new buffer will starte - the position where it will endCopyright © 2025 HtmlUnit. All rights reserved.