nashorn/src/jdk/nashorn/internal/objects/NativeUint16Array.java
changeset 16226 0e4f37e6cc40
parent 16151 97c1e756ae1e
child 17763 f30b7aa0e736
equal deleted inserted replaced
16225:81d58c2b9fcf 16226:0e4f37e6cc40
    34 
    34 
    35 /**
    35 /**
    36  * Uint16 array for TypedArray extension
    36  * Uint16 array for TypedArray extension
    37  */
    37  */
    38 @ScriptClass("Uint16Array")
    38 @ScriptClass("Uint16Array")
    39 public class NativeUint16Array extends ArrayBufferView {
    39 public final class NativeUint16Array extends ArrayBufferView {
    40     private static final int BYTES_PER_ELEMENT = 2;
    40     private static final int BYTES_PER_ELEMENT = 2;
    41     private static final Factory FACTORY = new Factory(BYTES_PER_ELEMENT) {
    41     private static final Factory FACTORY = new Factory(BYTES_PER_ELEMENT) {
    42         @Override
    42         @Override
    43         public ArrayBufferView construct(final NativeArrayBuffer buffer, final int byteOffset, final int length) {
    43         public ArrayBufferView construct(final NativeArrayBuffer buffer, final int byteOffset, final int length) {
    44             return new NativeUint16Array(buffer, byteOffset, length);
    44             return new NativeUint16Array(buffer, byteOffset, length);