private EzyByteBuffer getRemainBytes(EzyByteBuffer old)
 {
     if (!old.hasRemaining())
     {
         return(null);
     }
     byte[] bytes = new byte[old.remaining()];
     old.get(bytes);
     return(EzyByteBuffer.wrap(bytes));
 }
        public byte[] convert(EzyMessage message)
        {
            EzyByteBuffer buffer = newByteBuffer(message);

            writeHeader(buffer, message);
            writeSize(buffer, message);
            writeContent(buffer, message);
            byte[] answer = new byte[buffer.position()];
            buffer.flip();
            buffer.get(answer);
            return(answer);
        }
 protected Object parseFloat64(EzyByteBuffer buffer)
 {
     buffer.get();
     return(buffer.getDouble());
 }
 protected Object parseFloat32(EzyByteBuffer buffer)
 {
     buffer.get();
     return(buffer.getFloat());
 }
 protected override int getFix(EzyByteBuffer buffer)
 {
     return(buffer.get() & 0xF);
 }
 public Object deserialize(EzyByteBuffer buffer)
 {
     return(deserialize(buffer, buffer.get() & 0xff));
 }
 protected int getOther(EzyByteBuffer buffer, int nbytes)
 {
     buffer.get();
     return(buffer.getUInt(nbytes - 1));
 }
 protected long parseLong(EzyByteBuffer buffer, int size)
 {
     buffer.get();
     return(buffer.getLong(size));
 }
 protected int parseNegativeFixInt(EzyByteBuffer buffer)
 {
     return((sbyte)buffer.get());
 }
 protected int parsePositiveFixInt(EzyByteBuffer buffer)
 {
     return(buffer.get() & 0x7F);
 }
 protected Object parseValue(EzyByteBuffer buffer, Object value)
 {
     buffer.get();
     return(value);
 }
 protected int getBinLength(EzyByteBuffer buffer, int size)
 {
     buffer.get();
     return(buffer.getInt(size));
 }