コード例 #1
0
 public static Offset <FieldNode> CreateFieldNode(FlatBufferBuilder builder, long Length, long NullCount)
 {
     builder.Prep(8, 16);
     builder.PutLong(NullCount);
     builder.PutLong(Length);
     return(new Offset <FieldNode>(builder.Offset));
 }
コード例 #2
0
ファイル: Buffer.cs プロジェクト: TheVinhLuong102/arrow
 public static Offset <Buffer> CreateBuffer(FlatBufferBuilder builder, long Offset, long Length)
 {
     builder.Prep(8, 16);
     builder.PutLong(Length);
     builder.PutLong(Offset);
     return(new Offset <Buffer>(builder.Offset));
 }
コード例 #3
0
ファイル: Block.cs プロジェクト: TheVinhLuong102/arrow
 public static Offset <Block> CreateBlock(FlatBufferBuilder builder, long Offset, int MetaDataLength, long BodyLength)
 {
     builder.Prep(8, 24);
     builder.PutLong(BodyLength);
     builder.Pad(4);
     builder.PutInt(MetaDataLength);
     builder.PutLong(Offset);
     return(new Offset <Block>(builder.Offset));
 }
コード例 #4
0
 public static Offset <PlayerData> CreatePlayerData(FlatBufferBuilder builder, long UserId, float PosX, float PosY, bool Active)
 {
     builder.Prep(8, 24);
     builder.Pad(7);
     builder.PutBool(Active);
     builder.PutFloat(PosY);
     builder.PutFloat(PosX);
     builder.PutLong(UserId);
     return(new Offset <PlayerData>(builder.Offset));
 }
コード例 #5
0
 public static Offset <MyGame.Example.ArrayStruct> CreateArrayStruct(FlatBufferBuilder builder, float A, int[] B, sbyte C, int[,] d_A, MyGame.Example.TestEnum[] d_B, MyGame.Example.TestEnum[,] d_C, long[,] d_D, int E, long[] F)
 {
     builder.Prep(8, 160);
     for (int _idx0 = 2; _idx0 > 0; _idx0--)
     {
         builder.PutLong(F[_idx0 - 1]);
     }
     builder.Pad(4);
     builder.PutInt(E);
     for (int _idx0 = 2; _idx0 > 0; _idx0--)
     {
         builder.Prep(8, 32);
         for (int _idx1 = 2; _idx1 > 0; _idx1--)
         {
             builder.PutLong(d_D[_idx0 - 1, _idx1 - 1]);
         }
         builder.Pad(5);
         for (int _idx1 = 2; _idx1 > 0; _idx1--)
         {
             builder.PutSbyte((sbyte)d_C[_idx0 - 1, _idx1 - 1]);
         }
         builder.PutSbyte((sbyte)d_B[_idx0 - 1]);
         for (int _idx1 = 2; _idx1 > 0; _idx1--)
         {
             builder.PutInt(d_A[_idx0 - 1, _idx1 - 1]);
         }
     }
     builder.Pad(7);
     builder.PutSbyte(C);
     for (int _idx0 = 15; _idx0 > 0; _idx0--)
     {
         builder.PutInt(B[_idx0 - 1]);
     }
     builder.PutFloat(A);
     return(new Offset <MyGame.Example.ArrayStruct>(builder.Offset));
 }
コード例 #6
0
 public static Offset<MyGame.Example.NestedStruct> CreateNestedStruct(FlatBufferBuilder builder, int[] A, MyGame.Example.TestEnum B, MyGame.Example.TestEnum[] C, long[] D) {
   builder.Prep(8, 32);
   for (int _idx0 = 2; _idx0 > 0; _idx0--) {
     builder.PutLong(D[_idx0-1]);
   }
   builder.Pad(5);
   for (int _idx0 = 2; _idx0 > 0; _idx0--) {
     builder.PutSbyte((sbyte)C[_idx0-1]);
   }
   builder.PutSbyte((sbyte)B);
   for (int _idx0 = 2; _idx0 > 0; _idx0--) {
     builder.PutInt(A[_idx0-1]);
   }
   return new Offset<MyGame.Example.NestedStruct>(builder.Offset);
 }