ByteBuffer version of decodeLength decodeFirstValue