示例#1
0
 public static Offset <FlatSharpTests.Oracle.BasicTypes> CreateBasicTypes(FlatBufferBuilder builder,
                                                                          byte Byte                 = 0,
                                                                          ushort UShort             = 0,
                                                                          short Short               = 0,
                                                                          bool Bool                 = false,
                                                                          uint UInt                 = 0,
                                                                          int Int                   = 0,
                                                                          sbyte SByte               = 0,
                                                                          ulong ULong               = 0,
                                                                          long Long                 = 0,
                                                                          float Float               = 0.0f,
                                                                          double Double             = 0.0,
                                                                          StringOffset StringOffset = default(StringOffset))
 {
     builder.StartTable(12);
     BasicTypes.AddDouble(builder, Double);
     BasicTypes.AddLong(builder, Long);
     BasicTypes.AddULong(builder, ULong);
     BasicTypes.AddString(builder, StringOffset);
     BasicTypes.AddFloat(builder, Float);
     BasicTypes.AddInt(builder, Int);
     BasicTypes.AddUInt(builder, UInt);
     BasicTypes.AddShort(builder, Short);
     BasicTypes.AddUShort(builder, UShort);
     BasicTypes.AddSByte(builder, SByte);
     BasicTypes.AddBool(builder, Bool);
     BasicTypes.AddByte(builder, Byte);
     return(BasicTypes.EndBasicTypes(builder));
 }
示例#2
0
 public static BasicTypes GetRootAsBasicTypes(ByteBuffer _bb, BasicTypes obj)
 {
     return(obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb));
 }