Top "Bytebuffer" questions

A binary buffer with no specific encoding.

Java ByteBuffer performance issue

While processing multiple gigabyte files I noticed something odd: it seems that reading from a file using a filechannel into …

java performance nio bytebuffer
How write big endian ByteBuffer to little endian in Java

I currently have a Java ByteBuffer that already has the data in Big Endian format. I then want to write …

java bytebuffer endianness
How to get data from TCP socket into a ByteBuffer

I need to get incoming data from a socket into a ByteBuffer and I do not know how to do …

java sockets tcp bytebuffer socketchannel
Convert ByteBuffer to String in Java

I have a byte[] bytes from a ByteBuffer which contains a packet. I want to put the packet in a …

java bytearray bytebuffer
Fast ByteBuffer to CharBuffer or char[]

What is the fastest method to convert a java.nio.ByteBuffer a into a (newly created) CharBuffer b or char[] …

java bytearray nio bytebuffer arrays
Concat two ByteBuffers in Java

How can I concat two ByteBuffers to one ByteBuffer? The following doesn't work: ByteBuffer bb = ByteBuffer.allocate(100); ByteBuffer bb2 = ByteBuffer.…

java bytebuffer
Java - Heap vs Direct memory access

I recenty came across sun.misc.Unsafe class, allowing user to allocate,deallocate and in general access memory in a …

java memory-management heap memory-mapped-files bytebuffer
How to convert ByteBuffer into image in Android

I am receiving jpg image through socket and it is sent as ByteBuffer what I am doing is: ByteBuffer receivedData ; // …

android image bitmap bytearray bytebuffer
Manipulation of ByteBuffer from JNI

I need to pass a (direct) ByteBuffer to native functions that will read/write from/into the buffer. Once these …

java java-native-interface bytebuffer
ByteBuffer, CharBuffer, String and Charset

I'm trying to sort out characters, their representation in byte sequences according to character sets, and how to convert from …

java character-encoding bytebuffer