Beispiel #1
0
        public static string Unmarshal(ByteBuf buffer)
        {
            int len = buffer.readInt();

            if (len == NULL_STRING_LENGTH)
            {
                return(null);
            }

            sbyte[] bytes = new sbyte[len];
            buffer.readBytes(bytes);
            return(StringHelper.NewString(bytes, UTF_8));
        }
Beispiel #2
0
 public override int ReadInt()
 {
     return(_buf.readInt());
 }