Hacker News new | past | comments | ask | show | jobs | submit login

Well, with a MappedByteBuffer (or any DirectByteBuffer), if you want to manipulate the data as a Java type (e.g. byte[]) you have to copy the data into the heap. byte[] cannot exist outside of the heap.

Still, I wonder why they're using a MappedByteBuffer in the first place if they're working with the data in the Java heap.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: