Would a NIO ByteBuffer consistently offer a faster read performance than an IO BufferedStream?
If so,what would the reason be (keeping aside the multi-threading capbilities of NIO).
I read about minimized copying of the read data in the former case,while bringing the data from disk to application space.
Please help in understanding this - if this is actually true.
Asked
Active
Viewed 396 times
-1

IUnknown
- 9,301
- 15
- 50
- 76
-
2They do different things. – user253751 Feb 21 '15 at 05:59
1 Answers
0
They were made for different purposes.
ByteBuffer - it's just a byte buffer with a lot of convenience methods for manipulate data.
BufferedStream - it's the buffered implementation of InputStream. It's made to buffer data from one InputStream to another.

user207421
- 305,947
- 44
- 307
- 483

SergSW
- 238
- 2
- 10