I have a ByteBuffer
that can hold a maximum of (4 + size
) bytes
(that is, an integer followed by size
characters). However, the number of characters written to the ByteBuffer
, may be smaller than size
.
So I was wondering, is there anyway to determine how many characters were written to the ByteBuffer
and not just the total size of it? limit
, position
and such don't SEEM to be what I am after.
Thanks for your help!