|
GWT 2.7.0 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.google.gwt.typedarrays.client.DataViewNativeEmul
public class DataViewNativeEmul
JS native implementation of DataView for platforms with typed array
support but missing DataView (ie, Firefox).
| Field Summary | |
|---|---|
protected ArrayBuffer |
buffer
|
protected int |
bufferByteOffset
|
protected int |
byteLength
|
protected Uint8ArrayNative |
tempBuffer
A temporary buffer used for reversing bytes. |
protected Uint8ArrayNative |
uint8Array
A view of the underlying buffer as bytes. |
| Constructor Summary | |
|---|---|
protected |
DataViewNativeEmul(ArrayBuffer buffer,
int byteOffset,
int byteLength)
|
| Method Summary | |
|---|---|
ArrayBuffer |
buffer()
Get the underlying ArrayBuffer. |
int |
byteLength()
Get the length of this view in bytes. |
int |
byteOffset()
Get the offset from the beginning of the underlying ArrayBuffer. |
static DataView |
create(ArrayBuffer buffer,
int byteOffset,
int byteLength)
|
float |
getFloat32(int byteOffset)
|
float |
getFloat32(int byteOffset,
boolean littleEndian)
|
double |
getFloat64(int byteOffset)
|
double |
getFloat64(int byteOffset,
boolean littleEndian)
|
short |
getInt16(int byteOffset)
|
short |
getInt16(int byteOffset,
boolean littleEndian)
|
int |
getInt32(int byteOffset)
|
int |
getInt32(int byteOffset,
boolean littleEndian)
|
byte |
getInt8(int byteOffset)
|
int |
getUint16(int byteOffset)
|
int |
getUint16(int byteOffset,
boolean littleEndian)
|
long |
getUint32(int byteOffset)
|
long |
getUint32(int byteOffset,
boolean littleEndian)
|
double |
getUint32AsDouble(int byteOffset)
|
double |
getUint32AsDouble(int byteOffset,
boolean littleEndian)
|
short |
getUint8(int byteOffset)
|
protected void |
reverseBytes(Uint8ArrayNative src,
int srcOfs,
int len,
Uint8ArrayNative dest,
int destOfs)
Copy bytes from the underlying buffer to a temporary buffer, reversing them in the process. |
void |
setFloat32(int byteOffset,
float value)
|
void |
setFloat32(int byteOffset,
float value,
boolean littleEndian)
|
void |
setFloat64(int byteOffset,
double value)
|
void |
setFloat64(int byteOffset,
double value,
boolean littleEndian)
|
void |
setInt16(int byteOffset,
int value)
|
void |
setInt16(int byteOffset,
int value,
boolean littleEndian)
|
void |
setInt32(int byteOffset,
int value)
|
void |
setInt32(int byteOffset,
int value,
boolean littleEndian)
|
void |
setInt8(int byteOffset,
int value)
|
void |
setUint16(int byteOffset,
int value)
|
void |
setUint16(int byteOffset,
int value,
boolean littleEndian)
|
void |
setUint32(int byteOffset,
long value)
|
void |
setUint32(int byteOffset,
long value,
boolean littleEndian)
|
void |
setUint32FromDouble(int byteOffset,
double value)
|
void |
setUint32FromDouble(int byteOffset,
double value,
boolean littleEndian)
|
void |
setUint8(int byteOffset,
int value)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final ArrayBuffer buffer
protected final int bufferByteOffset
protected final int byteLength
protected final Uint8ArrayNative tempBuffer
protected final Uint8ArrayNative uint8Array
| Constructor Detail |
|---|
protected DataViewNativeEmul(ArrayBuffer buffer,
int byteOffset,
int byteLength)
| Method Detail |
|---|
public static DataView create(ArrayBuffer buffer,
int byteOffset,
int byteLength)
buffer - byteOffset - byteLength -
DataView instancepublic ArrayBuffer buffer()
ArrayBufferViewArrayBuffer.
buffer in interface ArrayBufferViewArrayBuffer instance backing this viewpublic int byteLength()
ArrayBufferView
byteLength in interface ArrayBufferViewpublic int byteOffset()
ArrayBufferViewArrayBuffer.
byteOffset in interface ArrayBufferViewArrayBufferView.buffer()public float getFloat32(int byteOffset)
getFloat32 in interface DataView
public float getFloat32(int byteOffset,
boolean littleEndian)
getFloat32 in interface DataViewpublic double getFloat64(int byteOffset)
getFloat64 in interface DataView
public double getFloat64(int byteOffset,
boolean littleEndian)
getFloat64 in interface DataViewpublic short getInt16(int byteOffset)
getInt16 in interface DataView
public short getInt16(int byteOffset,
boolean littleEndian)
getInt16 in interface DataViewpublic int getInt32(int byteOffset)
getInt32 in interface DataView
public int getInt32(int byteOffset,
boolean littleEndian)
getInt32 in interface DataViewpublic byte getInt8(int byteOffset)
getInt8 in interface DataViewpublic int getUint16(int byteOffset)
getUint16 in interface DataView
public int getUint16(int byteOffset,
boolean littleEndian)
getUint16 in interface DataViewpublic long getUint32(int byteOffset)
getUint32 in interface DataView
public long getUint32(int byteOffset,
boolean littleEndian)
getUint32 in interface DataViewpublic double getUint32AsDouble(int byteOffset)
getUint32AsDouble in interface DataView
public double getUint32AsDouble(int byteOffset,
boolean littleEndian)
getUint32AsDouble in interface DataViewpublic short getUint8(int byteOffset)
getUint8 in interface DataView
public void setFloat32(int byteOffset,
float value)
setFloat32 in interface DataView
public void setFloat32(int byteOffset,
float value,
boolean littleEndian)
setFloat32 in interface DataView
public void setFloat64(int byteOffset,
double value)
setFloat64 in interface DataView
public void setFloat64(int byteOffset,
double value,
boolean littleEndian)
setFloat64 in interface DataView
public void setInt16(int byteOffset,
int value)
setInt16 in interface DataView
public void setInt16(int byteOffset,
int value,
boolean littleEndian)
setInt16 in interface DataView
public void setInt32(int byteOffset,
int value)
setInt32 in interface DataView
public void setInt32(int byteOffset,
int value,
boolean littleEndian)
setInt32 in interface DataView
public void setInt8(int byteOffset,
int value)
setInt8 in interface DataView
public void setUint16(int byteOffset,
int value)
setUint16 in interface DataView
public void setUint16(int byteOffset,
int value,
boolean littleEndian)
setUint16 in interface DataView
public void setUint32(int byteOffset,
long value)
setUint32 in interface DataView
public void setUint32(int byteOffset,
long value,
boolean littleEndian)
setUint32 in interface DataView
public void setUint32FromDouble(int byteOffset,
double value)
setUint32FromDouble in interface DataView
public void setUint32FromDouble(int byteOffset,
double value,
boolean littleEndian)
setUint32FromDouble in interface DataView
public void setUint8(int byteOffset,
int value)
setUint8 in interface DataView
protected final void reverseBytes(Uint8ArrayNative src,
int srcOfs,
int len,
Uint8ArrayNative dest,
int destOfs)
src - srcOfs - offset into bufferlen - number of bytes to copydest - destOfs -
|
GWT 2.7.0 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||