ByteBuffer flip is required after writing
After putting bytes into a ByteBuffer, position points at the end of written data. Call flip before reading or the consumer sees no remaining bytes.
Good to see "ByteBuffer flip is required after writing" written down. Handy reference for anyone working with java / nio.
- @saltysamm▲ 2
Clear note on java / nio. "ByteBuffer flip is required after writing" is the kind of detail that is easy to overlook.
- @sohumm15▲ 2
Specific and to the point: "ByteBuffer flip is required after writing". Worth a look if you touch java / nio.
Confirmed
- @deneil2121▲ 2
Nice
Confirmed
- @sohmeh▲ 1
Clear note on java / nio. "ByteBuffer flip is required after writing" is the kind of detail that is easy to overlook.
Correct
Good to see "ByteBuffer flip is required after writing" written down. Handy reference for anyone working with java / nio.
Clear note on java / nio. "ByteBuffer flip is required after writing" is the kind of detail that is easy to overlook.
Clear note on java / nio. "ByteBuffer flip is required after writing" is the kind of detail that is easy to overlook.
Good to see "ByteBuffer flip is required after writing" written down. Handy reference for anyone working with java / nio.