Has anyone has ever seen an implementation of java.nio.ByteBuffer that will grow dynamically if a putX() call overruns the capacity?
The reason I want to do it this way is twofold:
1) I don't know how much space I need ahead of time. 2) I'd rather not do a new ByteBuffer.allocate() then a bulk put() every time I run out of space.
I could try writing one myself, but don't want to reinvent the wheel if one of these already exists somewhere.
Any suggestions?