Пример #1
0
        public static SEAT_SETTLE decode(byte[] data)
        {
            SEAT_SETTLE proto = newBuilder();

            proto.build(data);
            return(proto);
        }
Пример #2
0
 public void addSeatSettle(SEAT_SETTLE value)
 {
     if (!this.hasSeatSettle())
     {
         this.__flag[0] = (byte)(this.__flag[0] | 1);
     }
     this.seat_settle.Add(value);
 }
Пример #3
0
        public void build(byte[] data)
        {
            ByteBuffer buf = ByteBuffer.wrap(data);

            for (int i = 0; i < this.__flag.Length; i++)
            {
                this.__flag[i] = buf.get();
            }

            if (this.hasSeatSettle())
            {
                int size = buf.getShort();
                for (int i = 0; i < size; i++)
                {
                    byte[] bytes = new byte[buf.getInt()];
                    buf.get(ref bytes, 0, bytes.Length);
                    this.seat_settle.Add(SEAT_SETTLE.decode(bytes));
                }
            }
        }