List of utility methods to do ByteBuffer Flip
int | transfer(@Nonnull final ByteBuffer aSrcBuffer, @Nonnull final ByteBuffer aDstBuffer, final boolean bNeedsFlip) Transfer as much as possible from source to dest buffer. if (aSrcBuffer == null) throw new NullPointerException("srcBuffer"); if (aDstBuffer == null) throw new NullPointerException("dstBuffer"); int nRead = 0; if (bNeedsFlip) { if (aSrcBuffer.position() > 0) { aSrcBuffer.flip(); ... |