ByteBufferUtil

public class ByteBufferUtil
extends Object

java.lang.Object
   ↳ com.android.ddmlib.ByteBufferUtil


Resumo

Construtores públicos

ByteBufferUtil()

Métodos públicos

static boolean cleanBuffer(ByteBuffer buffer)

Use com cuidado.

static String getString(ByteBuffer buf, int len)
static ByteBuffer mapFile(File f, long offset, ByteOrder byteOrder)
static void putString(ByteBuffer buf, String str)

Construtores públicos

ByteBufferUtil

public ByteBufferUtil ()

Métodos públicos

cleanBuffer

public static boolean cleanBuffer (ByteBuffer buffer)

Use com cuidado. Na maioria dos casos, deixar o trabalho para o GC é suficiente.

Parâmetros
buffer ByteBuffer

Retorna
boolean

getString

public static String getString (ByteBuffer buf, 
                int len)

Parâmetros
buf ByteBuffer

len int

Retorna
String

mapFile

public static ByteBuffer mapFile (File f, 
                long offset, 
                ByteOrder byteOrder)

Parâmetros
f File

offset long

byteOrder ByteOrder

Retorna
ByteBuffer

putString

public static void putString (ByteBuffer buf, 
                String str)

Parâmetros
buf ByteBuffer

str String