|
@@ -782,27 +782,32 @@ type
|
|
|
|
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+ IJSArrayBufferView = interface (IJSObject) ['{E4585865-E907-40CE-B3E5-7E5E343EBED6}']
|
|
|
|
+
|
|
|
|
+ function _getBuffer: IJSArrayBuffer;
|
|
|
|
+ function _getByteLength: NativeInt;
|
|
|
|
+ function _getByteOffset: NativeInt;
|
|
|
|
+
|
|
|
|
+ property buffer : IJSArrayBuffer Read _getBuffer;
|
|
|
|
+ property byteLength : NativeInt Read _getByteLength;
|
|
|
|
+ property byteOffset : NativeInt Read _getByteOffset;
|
|
|
|
+ end;
|
|
|
|
+
|
|
{ IJSTypedArray }
|
|
{ IJSTypedArray }
|
|
|
|
|
|
- IJSTypedArray = interface(IJSObject)
|
|
|
|
|
|
+ IJSTypedArray = interface(IJSArrayBufferView)
|
|
['{6A76602B-9555-4136-A7B7-2E683265EA82}']
|
|
['{6A76602B-9555-4136-A7B7-2E683265EA82}']
|
|
- function GetBuffer: IJSArrayBuffer;
|
|
|
|
function _GetLength: NativeInt;
|
|
function _GetLength: NativeInt;
|
|
- function _GetByteLength: NativeInt;
|
|
|
|
- function _GetByteOffset: NativeInt;
|
|
|
|
procedure set_(aArray : IJSTypedArray; TargetOffset : Integer);
|
|
procedure set_(aArray : IJSTypedArray; TargetOffset : Integer);
|
|
procedure set_(aArray : IJSTypedArray);
|
|
procedure set_(aArray : IJSTypedArray);
|
|
- property Buffer : IJSArrayBuffer read GetBuffer;
|
|
|
|
Property Length: NativeInt Read _GetLength;
|
|
Property Length: NativeInt Read _GetLength;
|
|
- Property byteLength: NativeInt Read _GetByteLength;
|
|
|
|
- Property byteOffset: NativeInt Read _GetByteOffset;
|
|
|
|
end;
|
|
end;
|
|
|
|
|
|
{ TJSTypedArray }
|
|
{ TJSTypedArray }
|
|
|
|
|
|
TJSTypedArray = class(TJSObject,IJSTypedArray)
|
|
TJSTypedArray = class(TJSObject,IJSTypedArray)
|
|
- private
|
|
|
|
- function GetBuffer: IJSArrayBuffer;
|
|
|
|
|
|
+ protected
|
|
|
|
+ function _GetBuffer: IJSArrayBuffer;
|
|
function _GetLength: NativeInt;
|
|
function _GetLength: NativeInt;
|
|
function _GetByteLength: NativeInt;
|
|
function _GetByteLength: NativeInt;
|
|
function _GetByteOffset: NativeInt;
|
|
function _GetByteOffset: NativeInt;
|
|
@@ -815,12 +820,15 @@ type
|
|
class function Cast(const Intf: IJSObject): IJSTypedArray; overload;
|
|
class function Cast(const Intf: IJSObject): IJSTypedArray; overload;
|
|
procedure set_(aArray : IJSTypedArray; TargetOffset : Integer);
|
|
procedure set_(aArray : IJSTypedArray; TargetOffset : Integer);
|
|
procedure set_(aArray : IJSTypedArray);
|
|
procedure set_(aArray : IJSTypedArray);
|
|
- property Buffer : IJSArrayBuffer read GetBuffer;
|
|
|
|
|
|
+ property Buffer : IJSArrayBuffer read _GetBuffer;
|
|
Property Length: NativeInt Read _GetLength;
|
|
Property Length: NativeInt Read _GetLength;
|
|
Property byteLength: NativeInt Read _GetByteLength;
|
|
Property byteLength: NativeInt Read _GetByteLength;
|
|
Property byteOffset: NativeInt Read _GetByteOffset;
|
|
Property byteOffset: NativeInt Read _GetByteOffset;
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+ // We need to be able to create a IJSArrayBufferView
|
|
|
|
+ TJSArrayBufferView = TJSTypedArray;
|
|
|
|
+
|
|
{ IJSInt8Array }
|
|
{ IJSInt8Array }
|
|
|
|
|
|
IJSInt8Array = interface(IJSTypedArray)
|
|
IJSInt8Array = interface(IJSTypedArray)
|
|
@@ -1024,103 +1032,99 @@ type
|
|
class function Cast(const Intf: IJSObject): IJSBufferSource; overload;
|
|
class function Cast(const Intf: IJSObject): IJSBufferSource; overload;
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+
|
|
|
|
+
|
|
{ IJSDataView }
|
|
{ IJSDataView }
|
|
|
|
|
|
- IJSDataView = interface(IJSObject)
|
|
|
|
|
|
+ IJSDataView = interface(IJSArrayBufferView)
|
|
['{42F14387-FAD2-46BA-8CB4-057445095CEE}']
|
|
['{42F14387-FAD2-46BA-8CB4-057445095CEE}']
|
|
- function _getBuffer: IJSArrayBuffer;
|
|
|
|
- function _getByteLength: Longint;
|
|
|
|
- function _getByteOffset: Longint;
|
|
|
|
-
|
|
|
|
- function getBigInt64(byteOffset : Longint) : Int64;
|
|
|
|
- function getBigInt64(byteOffset : Longint; littleEndian : Boolean) : Int64;
|
|
|
|
- function getInt32(byteOffset : Longint) : Longint;
|
|
|
|
- function getInt32(byteOffset : Longint; littleEndian : Boolean) : Longint;
|
|
|
|
- function getInt16(byteOffset : Longint) : Smallint;
|
|
|
|
- function getInt16(byteOffset : Longint; littleEndian : Boolean) : Smallint;
|
|
|
|
- function getInt8(byteOffset : Longint) : ShortInt;
|
|
|
|
- function getUint32(byteOffset : Longint) : Cardinal;
|
|
|
|
- function getUint32(byteOffset : Longint; littleEndian : Boolean) : Cardinal;
|
|
|
|
- function getUint16(byteOffset : Longint) : Word;
|
|
|
|
- function getUint16(byteOffset : Longint; littleEndian : Boolean) : Word;
|
|
|
|
- function getUint8(byteOffset : Longint) : Byte;
|
|
|
|
- function getFloat64(byteOffset : Longint) : Double;
|
|
|
|
- function getFloat64(byteOffset : Longint; littleEndian : Boolean) : Double;
|
|
|
|
- function getFloat32(byteOffset : Longint) : Single;
|
|
|
|
- function getFloat32(byteOffset : Longint; littleEndian : Boolean) : Single;
|
|
|
|
-
|
|
|
|
- procedure setBigInt64(byteOffset : Longint; aValue : Int64);
|
|
|
|
- procedure setBigInt64(byteOffset : Longint; aValue : Int64; littleEndian : Boolean);
|
|
|
|
- procedure setInt32(byteOffset : Longint; aValue : Longint);
|
|
|
|
- procedure setInt32(byteOffset : Longint; aValue : Longint; littleEndian : Boolean);
|
|
|
|
- procedure setInt16(byteOffset : Longint; aValue : Smallint);
|
|
|
|
- procedure setInt16(byteOffset : Longint; aValue : Smallint; littleEndian : Boolean);
|
|
|
|
- procedure setInt8(byteOffset : Longint; aValue : Shortint);
|
|
|
|
- procedure setUint32(byteOffset : Longint; aValue : Cardinal);
|
|
|
|
- procedure setUint32(byteOffset : Longint; aValue : Cardinal; littleEndian : Boolean);
|
|
|
|
- procedure setUint16(byteOffset : Longint; aValue : Word);
|
|
|
|
- procedure setUint16(byteOffset : Longint; aValue : Word; littleEndian : Boolean);
|
|
|
|
- procedure setUint8(byteOffset : Longint; aValue : Byte);
|
|
|
|
- procedure setFloat64(byteOffset : Longint; aValue: Double);
|
|
|
|
- procedure setFloat64(byteOffset : Longint; aValue : Double; littleEndian : Boolean);
|
|
|
|
- procedure setFloat32(byteOffset : Longint; aValue : Single);
|
|
|
|
- procedure setFloat32(byteOffset : Longint; aValue : Single; littleEndian : Boolean);
|
|
|
|
|
|
|
|
- property buffer : IJSArrayBuffer Read _getBuffer;
|
|
|
|
- property byteLength : Longint Read _getByteLength;
|
|
|
|
- property byteOffset : Longint Read _getByteOffset;
|
|
|
|
|
|
+ function getBigInt64(aByteOffset : Longint) : Int64;
|
|
|
|
+ function getBigInt64(aByteOffset : Longint; littleEndian : Boolean) : Int64;
|
|
|
|
+ function getInt32(aByteOffset : Longint) : Longint;
|
|
|
|
+ function getInt32(aByteOffset : Longint; littleEndian : Boolean) : Longint;
|
|
|
|
+ function getInt16(aByteOffset : Longint) : Smallint;
|
|
|
|
+ function getInt16(aByteOffset : Longint; littleEndian : Boolean) : Smallint;
|
|
|
|
+ function getInt8(aByteOffset : Longint) : ShortInt;
|
|
|
|
+ function getUint32(aByteOffset : Longint) : Cardinal;
|
|
|
|
+ function getUint32(aByteOffset : Longint; littleEndian : Boolean) : Cardinal;
|
|
|
|
+ function getUint16(aByteOffset : Longint) : Word;
|
|
|
|
+ function getUint16(aByteOffset : Longint; littleEndian : Boolean) : Word;
|
|
|
|
+ function getUint8(aByteOffset : Longint) : Byte;
|
|
|
|
+ function getFloat64(aByteOffset : Longint) : Double;
|
|
|
|
+ function getFloat64(aByteOffset : Longint; littleEndian : Boolean) : Double;
|
|
|
|
+ function getFloat32(aByteOffset : Longint) : Single;
|
|
|
|
+ function getFloat32(aByteOffset : Longint; littleEndian : Boolean) : Single;
|
|
|
|
+
|
|
|
|
+ procedure setBigInt64(aByteOffset : Longint; aValue : Int64);
|
|
|
|
+ procedure setBigInt64(aByteOffset : Longint; aValue : Int64; littleEndian : Boolean);
|
|
|
|
+ procedure setInt32(aByteOffset : Longint; aValue : Longint);
|
|
|
|
+ procedure setInt32(aByteOffset : Longint; aValue : Longint; littleEndian : Boolean);
|
|
|
|
+ procedure setInt16(aByteOffset : Longint; aValue : Smallint);
|
|
|
|
+ procedure setInt16(aByteOffset : Longint; aValue : Smallint; littleEndian : Boolean);
|
|
|
|
+ procedure setInt8(aByteOffset : Longint; aValue : Shortint);
|
|
|
|
+ procedure setUint32(aByteOffset : Longint; aValue : Cardinal);
|
|
|
|
+ procedure setUint32(aByteOffset : Longint; aValue : Cardinal; littleEndian : Boolean);
|
|
|
|
+ procedure setUint16(aByteOffset : Longint; aValue : Word);
|
|
|
|
+ procedure setUint16(aByteOffset : Longint; aValue : Word; littleEndian : Boolean);
|
|
|
|
+ procedure setUint8(aByteOffset : Longint; aValue : Byte);
|
|
|
|
+ procedure setFloat64(aByteOffset : Longint; aValue: Double);
|
|
|
|
+ procedure setFloat64(aByteOffset : Longint; aValue : Double; littleEndian : Boolean);
|
|
|
|
+ procedure setFloat32(aByteOffset : Longint; aValue : Single);
|
|
|
|
+ procedure setFloat32(aByteOffset : Longint; aValue : Single; littleEndian : Boolean);
|
|
|
|
+
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+
|
|
|
|
+
|
|
{ TJSDataView }
|
|
{ TJSDataView }
|
|
|
|
|
|
TJSDataView = class(TJSObject,IJSDataView)
|
|
TJSDataView = class(TJSObject,IJSDataView)
|
|
protected
|
|
protected
|
|
function _getBuffer: IJSArrayBuffer;
|
|
function _getBuffer: IJSArrayBuffer;
|
|
- function _getByteLength: Longint;
|
|
|
|
- function _getByteOffset: Longint;
|
|
|
|
|
|
+ function _getByteLength: NativeInt;
|
|
|
|
+ function _getByteOffset: NativeInt;
|
|
public
|
|
public
|
|
constructor create(aBuffer : IJSArrayBuffer);
|
|
constructor create(aBuffer : IJSArrayBuffer);
|
|
constructor create(aBuffer : IJSArrayBuffer; aOffset : longint);
|
|
constructor create(aBuffer : IJSArrayBuffer; aOffset : longint);
|
|
constructor create(aBuffer : IJSArrayBuffer; aOffset, aByteLength : longint);
|
|
constructor create(aBuffer : IJSArrayBuffer; aOffset, aByteLength : longint);
|
|
class function JSClassName: UnicodeString; override;
|
|
class function JSClassName: UnicodeString; override;
|
|
class function Cast(const Intf: IJSObject): IJSDataView; overload;
|
|
class function Cast(const Intf: IJSObject): IJSDataView; overload;
|
|
- function getBigInt64(byteOffset : Longint) : Int64;
|
|
|
|
- function getBigInt64(byteOffset : Longint; littleEndian : Boolean) : Int64;
|
|
|
|
- function getInt32(byteOffset : Longint) : Longint;
|
|
|
|
- function getInt32(byteOffset : Longint; littleEndian : Boolean) : Longint;
|
|
|
|
- function getInt16(byteOffset : Longint) : Smallint;
|
|
|
|
- function getInt16(byteOffset : Longint; littleEndian : Boolean) : Smallint;
|
|
|
|
- function getInt8(byteOffset : Longint) : ShortInt;
|
|
|
|
- function getUint32(byteOffset : Longint) : Cardinal;
|
|
|
|
- function getUint32(byteOffset : Longint; littleEndian : Boolean) : Cardinal;
|
|
|
|
- function getUint16(byteOffset : Longint) : Word;
|
|
|
|
- function getUint16(byteOffset : Longint; littleEndian : Boolean) : Word;
|
|
|
|
- function getUint8(byteOffset : Longint) : Byte;
|
|
|
|
- function getFloat64(byteOffset : Longint) : Double;
|
|
|
|
- function getFloat64(byteOffset : Longint; littleEndian : Boolean) : Double;
|
|
|
|
- function getFloat32(byteOffset : Longint) : Single;
|
|
|
|
- function getFloat32(byteOffset : Longint; littleEndian : Boolean) : Single;
|
|
|
|
-
|
|
|
|
- procedure setBigInt64(byteOffset : Longint; aValue : Int64);
|
|
|
|
- procedure setBigInt64(byteOffset : Longint; aValue : Int64; littleEndian : Boolean);
|
|
|
|
- procedure setInt32(byteOffset : Longint; aValue : Longint);
|
|
|
|
- procedure setInt32(byteOffset : Longint; aValue : Longint; littleEndian : Boolean);
|
|
|
|
- procedure setInt16(byteOffset : Longint; aValue : Smallint);
|
|
|
|
- procedure setInt16(byteOffset : Longint; aValue : Smallint; littleEndian : Boolean);
|
|
|
|
- procedure setInt8(byteOffset : Longint; aValue : Shortint);
|
|
|
|
- procedure setUint32(byteOffset : Longint; aValue : Cardinal);
|
|
|
|
- procedure setUint32(byteOffset : Longint; aValue : Cardinal; littleEndian : Boolean);
|
|
|
|
- procedure setUint16(byteOffset : Longint; aValue : Word);
|
|
|
|
- procedure setUint16(byteOffset : Longint; aValue : Word; littleEndian : Boolean);
|
|
|
|
- procedure setUint8(byteOffset : Longint; aValue : Byte);
|
|
|
|
- procedure setFloat64(byteOffset : Longint; aValue: Double);
|
|
|
|
- procedure setFloat64(byteOffset : Longint; aValue : Double; littleEndian : Boolean);
|
|
|
|
- procedure setFloat32(byteOffset : Longint; aValue : Single);
|
|
|
|
- procedure setFloat32(byteOffset : Longint; aValue : Single; littleEndian : Boolean);
|
|
|
|
|
|
+ function getBigInt64(aByteOffset : Longint) : Int64;
|
|
|
|
+ function getBigInt64(aByteOffset : Longint; littleEndian : Boolean) : Int64;
|
|
|
|
+ function getInt32(aByteOffset : Longint) : Longint;
|
|
|
|
+ function getInt32(aByteOffset : Longint; littleEndian : Boolean) : Longint;
|
|
|
|
+ function getInt16(aByteOffset : Longint) : Smallint;
|
|
|
|
+ function getInt16(aByteOffset : Longint; littleEndian : Boolean) : Smallint;
|
|
|
|
+ function getInt8(aByteOffset : Longint) : ShortInt;
|
|
|
|
+ function getUint32(aByteOffset : Longint) : Cardinal;
|
|
|
|
+ function getUint32(aByteOffset : Longint; littleEndian : Boolean) : Cardinal;
|
|
|
|
+ function getUint16(aByteOffset : Longint) : Word;
|
|
|
|
+ function getUint16(aByteOffset : Longint; littleEndian : Boolean) : Word;
|
|
|
|
+ function getUint8(aByteOffset : Longint) : Byte;
|
|
|
|
+ function getFloat64(aByteOffset : Longint) : Double;
|
|
|
|
+ function getFloat64(aByteOffset : Longint; littleEndian : Boolean) : Double;
|
|
|
|
+ function getFloat32(aByteOffset : Longint) : Single;
|
|
|
|
+ function getFloat32(aByteOffset : Longint; littleEndian : Boolean) : Single;
|
|
|
|
+
|
|
|
|
+ procedure setBigInt64(aByteOffset : Longint; aValue : Int64);
|
|
|
|
+ procedure setBigInt64(aByteOffset : Longint; aValue : Int64; littleEndian : Boolean);
|
|
|
|
+ procedure setInt32(aByteOffset : Longint; aValue : Longint);
|
|
|
|
+ procedure setInt32(aByteOffset : Longint; aValue : Longint; littleEndian : Boolean);
|
|
|
|
+ procedure setInt16(aByteOffset : Longint; aValue : Smallint);
|
|
|
|
+ procedure setInt16(aByteOffset : Longint; aValue : Smallint; littleEndian : Boolean);
|
|
|
|
+ procedure setInt8(aByteOffset : Longint; aValue : Shortint);
|
|
|
|
+ procedure setUint32(aByteOffset : Longint; aValue : Cardinal);
|
|
|
|
+ procedure setUint32(aByteOffset : Longint; aValue : Cardinal; littleEndian : Boolean);
|
|
|
|
+ procedure setUint16(aByteOffset : Longint; aValue : Word);
|
|
|
|
+ procedure setUint16(aByteOffset : Longint; aValue : Word; littleEndian : Boolean);
|
|
|
|
+ procedure setUint8(aByteOffset : Longint; aValue : Byte);
|
|
|
|
+ procedure setFloat64(aByteOffset : Longint; aValue: Double);
|
|
|
|
+ procedure setFloat64(aByteOffset : Longint; aValue : Double; littleEndian : Boolean);
|
|
|
|
+ procedure setFloat32(aByteOffset : Longint; aValue : Single);
|
|
|
|
+ procedure setFloat32(aByteOffset : Longint; aValue : Single; littleEndian : Boolean);
|
|
end;
|
|
end;
|
|
|
|
|
|
- IJSArrayBufferView = IJSDataView;
|
|
|
|
- TJSArrayBufferView = TJSDataView;
|
|
|
|
|
|
|
|
{ IJSJSON }
|
|
{ IJSJSON }
|
|
|
|
|
|
@@ -1728,12 +1732,12 @@ begin
|
|
Result:=ReadJSPropertyObject('buffer',TJSArrayBuffer) as IJSArrayBuffer;
|
|
Result:=ReadJSPropertyObject('buffer',TJSArrayBuffer) as IJSArrayBuffer;
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView._getByteLength: Longint;
|
|
|
|
|
|
+function TJSDataView._getByteLength: NativeInt;
|
|
begin
|
|
begin
|
|
Result:=ReadJSPropertyLongInt('byteLength');
|
|
Result:=ReadJSPropertyLongInt('byteLength');
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView._getByteOffset: Longint;
|
|
|
|
|
|
+function TJSDataView._getByteOffset: NativeInt;
|
|
begin
|
|
begin
|
|
Result:=ReadJSPropertyLongInt('byteOffset');
|
|
Result:=ReadJSPropertyLongInt('byteOffset');
|
|
end;
|
|
end;
|
|
@@ -1763,164 +1767,164 @@ begin
|
|
Result:=TJSDataView.JOBCast(Intf);
|
|
Result:=TJSDataView.JOBCast(Intf);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getBigInt64(byteOffset: Longint): Int64;
|
|
|
|
|
|
+function TJSDataView.getBigInt64(aByteOffset: Longint): Int64;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSMaxIntResult('getBigInt64',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSMaxIntResult('getBigInt64',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getBigInt64(byteOffset: Longint; littleEndian: Boolean): Int64;
|
|
|
|
|
|
+function TJSDataView.getBigInt64(aByteOffset: Longint; littleEndian: Boolean): Int64;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSMaxIntResult('getBigInt64',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSMaxIntResult('getBigInt64',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getInt32(byteOffset: Longint): Longint;
|
|
|
|
|
|
+function TJSDataView.getInt32(aByteOffset: Longint): Longint;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getInt32',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getInt32',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getInt32(byteOffset: Longint; littleEndian: Boolean): Longint;
|
|
|
|
|
|
+function TJSDataView.getInt32(aByteOffset: Longint; littleEndian: Boolean): Longint;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getInt32',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getInt32',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getInt16(byteOffset: Longint): Smallint;
|
|
|
|
|
|
+function TJSDataView.getInt16(aByteOffset: Longint): Smallint;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getInt16',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getInt16',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getInt16(byteOffset: Longint; littleEndian: Boolean): Smallint;
|
|
|
|
|
|
+function TJSDataView.getInt16(aByteOffset: Longint; littleEndian: Boolean): Smallint;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getInt16',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getInt16',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getInt8(byteOffset: Longint): ShortInt;
|
|
|
|
|
|
+function TJSDataView.getInt8(aByteOffset: Longint): ShortInt;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getInt8',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getInt8',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getUint32(byteOffset: Longint): Cardinal;
|
|
|
|
|
|
+function TJSDataView.getUint32(aByteOffset: Longint): Cardinal;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSMaxIntResult('getUint32',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSMaxIntResult('getUint32',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getUint32(byteOffset: Longint; littleEndian: Boolean): Cardinal;
|
|
|
|
|
|
+function TJSDataView.getUint32(aByteOffset: Longint; littleEndian: Boolean): Cardinal;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSMaxIntResult('getUint32',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSMaxIntResult('getUint32',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getUint16(byteOffset: Longint): Word;
|
|
|
|
|
|
+function TJSDataView.getUint16(aByteOffset: Longint): Word;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getUint16',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getUint16',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getUint16(byteOffset: Longint; littleEndian: Boolean): Word;
|
|
|
|
|
|
+function TJSDataView.getUint16(aByteOffset: Longint; littleEndian: Boolean): Word;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getUint16',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getUint16',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getUint8(byteOffset: Longint): Byte;
|
|
|
|
|
|
+function TJSDataView.getUint8(aByteOffset: Longint): Byte;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSLongIntResult('getUint8',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSLongIntResult('getUint8',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getFloat64(byteOffset: Longint): Double;
|
|
|
|
|
|
+function TJSDataView.getFloat64(aByteOffset: Longint): Double;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSDoubleResult('getFloat64',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSDoubleResult('getFloat64',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getFloat64(byteOffset: Longint; littleEndian: Boolean): Double;
|
|
|
|
|
|
+function TJSDataView.getFloat64(aByteOffset: Longint; littleEndian: Boolean): Double;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSDoubleResult('getFloat64',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSDoubleResult('getFloat64',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getFloat32(byteOffset: Longint): Single;
|
|
|
|
|
|
+function TJSDataView.getFloat32(aByteOffset: Longint): Single;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSDoubleResult('getFloat32',[byteOffset],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSDoubleResult('getFloat32',[aByteOffset],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-function TJSDataView.getFloat32(byteOffset: Longint; littleEndian: Boolean): Single;
|
|
|
|
|
|
+function TJSDataView.getFloat32(aByteOffset: Longint; littleEndian: Boolean): Single;
|
|
begin
|
|
begin
|
|
- Result:=InvokeJSDoubleResult('getFloat32',[byteOffset,littleEndian],jiCall);
|
|
|
|
|
|
+ Result:=InvokeJSDoubleResult('getFloat32',[aByteOffset,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setBigInt64(byteOffset: Longint; aValue: Int64);
|
|
|
|
|
|
+procedure TJSDataView.setBigInt64(aByteOffset: Longint; aValue: Int64);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setBigInt64',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setBigInt64',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setBigInt64(byteOffset: Longint; aValue: Int64; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setBigInt64(aByteOffset: Longint; aValue: Int64; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setBigInt64',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setBigInt64',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setInt32(byteOffset: Longint; aValue: Longint);
|
|
|
|
|
|
+procedure TJSDataView.setInt32(aByteOffset: Longint; aValue: Longint);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setInt32',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setInt32',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setInt32(byteOffset: Longint; aValue: Longint; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setInt32(aByteOffset: Longint; aValue: Longint; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setInt32',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setInt32',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setInt16(byteOffset: Longint; aValue: Smallint);
|
|
|
|
|
|
+procedure TJSDataView.setInt16(aByteOffset: Longint; aValue: Smallint);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setInt16',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setInt16',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setInt16(byteOffset: Longint; aValue: Smallint; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setInt16(aByteOffset: Longint; aValue: Smallint; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setInt16',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setInt16',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setInt8(byteOffset: Longint; aValue: Shortint);
|
|
|
|
|
|
+procedure TJSDataView.setInt8(aByteOffset: Longint; aValue: Shortint);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setInt8',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setInt8',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setUint32(byteOffset: Longint; aValue: Cardinal);
|
|
|
|
|
|
+procedure TJSDataView.setUint32(aByteOffset: Longint; aValue: Cardinal);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setUint32',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setUint32',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setUint32(byteOffset: Longint; aValue: Cardinal; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setUint32(aByteOffset: Longint; aValue: Cardinal; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setUint32',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setUint32',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setUint16(byteOffset: Longint; aValue: Word);
|
|
|
|
|
|
+procedure TJSDataView.setUint16(aByteOffset: Longint; aValue: Word);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setUint16',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setUint16',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setUint16(byteOffset: Longint; aValue: Word; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setUint16(aByteOffset: Longint; aValue: Word; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setUint16',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setUint16',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setUint8(byteOffset: Longint; aValue: Byte);
|
|
|
|
|
|
+procedure TJSDataView.setUint8(aByteOffset: Longint; aValue: Byte);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setUint8',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setUint8',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setFloat64(byteOffset: Longint; aValue: Double);
|
|
|
|
|
|
+procedure TJSDataView.setFloat64(aByteOffset: Longint; aValue: Double);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setFloat64',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setFloat64',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setFloat64(byteOffset: Longint; aValue: Double; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setFloat64(aByteOffset: Longint; aValue: Double; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setFloat64',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setFloat64',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setFloat32(byteOffset: Longint; aValue: Single);
|
|
|
|
|
|
+procedure TJSDataView.setFloat32(aByteOffset: Longint; aValue: Single);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setFloat32',[byteOffset,aValue],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setFloat32',[aByteOffset,aValue],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
-procedure TJSDataView.setFloat32(byteOffset: Longint; aValue: Single; littleEndian: Boolean);
|
|
|
|
|
|
+procedure TJSDataView.setFloat32(aByteOffset: Longint; aValue: Single; littleEndian: Boolean);
|
|
begin
|
|
begin
|
|
- InvokeJSNoResult('setFloat32',[byteOffset,aValue,littleEndian],jiCall);
|
|
|
|
|
|
+ InvokeJSNoResult('setFloat32',[aByteOffset,aValue,littleEndian],jiCall);
|
|
end;
|
|
end;
|
|
|
|
|
|
{ TJSBufferSource }
|
|
{ TJSBufferSource }
|
|
@@ -2138,7 +2142,7 @@ end;
|
|
|
|
|
|
{ TJSTypedArray }
|
|
{ TJSTypedArray }
|
|
|
|
|
|
-function TJSTypedArray.GetBuffer: IJSArrayBuffer;
|
|
|
|
|
|
+function TJSTypedArray._GetBuffer: IJSArrayBuffer;
|
|
begin
|
|
begin
|
|
Result:=ReadJSPropertyObject('buffer',TJSArrayBuffer) as IJSArrayBuffer;
|
|
Result:=ReadJSPropertyObject('buffer',TJSArrayBuffer) as IJSArrayBuffer;
|
|
end;
|
|
end;
|