Variable length encoding ByteBuf implementation