Пример #1
0
 public static byte[] ToBytes(Puerts.ArrayBuffer value)
 {
     if (value != null)
     {
         var source = value.Bytes;
         var result = new byte[source.Length];
         Array.Copy(source, 0, result, 0, source.Length);
         return(result);
     }
     return(null);
 }
Пример #2
0
 public void Send(long sessionId, Puerts.ArrayBuffer buffer, int offset, int len)
 {
     base.GetSocket(sessionId)?.Send(buffer.Bytes, offset, len);
 }
Пример #3
0
 public static void ArrayBufferArgChecked(Puerts.ArrayBuffer value)
 {
     Assert.IsTrue(value.Bytes.Length > 0);
 }
Пример #4
0
 public static void ArrayBufferArg(Puerts.ArrayBuffer value)
 {
 }
Пример #5
0
 public static void ArrayBufferRef(ref Puerts.ArrayBuffer value)
 {
     byte[] bytes = { 1 }; value = new ArrayBuffer(bytes);                                                               /*一时没想到怎么修改ab,先留着*/
 }
Пример #6
0
 public static void ArrayBufferOut(out Puerts.ArrayBuffer value)
 {
     byte[] bytes = { 1 }; value = new ArrayBuffer(bytes);
 }
 public static void PushArrayBuffer(int jsEnvIdx, IntPtr isolate, ISetValueToJs setValueApi, IntPtr holder, ArrayBuffer arrayBuffer)
 {
     setValueApi.SetArrayBuffer(isolate, holder, arrayBuffer);
 }