public class NativeBuffer extends Object
Modifier and Type | Field and Description |
---|---|
protected long |
self |
Modifier and Type | Method and Description |
---|---|
protected void |
assertAllocated() |
long |
capacity() |
static NativeBuffer |
create(byte[] data) |
static NativeBuffer |
create(byte[] data,
int offset,
int length) |
static NativeBuffer |
create(long capacity) |
static NativeBuffer |
create(String data) |
void |
delete() |
NativeBuffer |
head(long length) |
boolean |
isAllocated() |
static void |
popMemoryPool() |
static void |
pushMemoryPool(int size) |
void |
read(long at,
byte[] target,
int offset,
int length) |
NativeBuffer |
slice(long offset,
long length) |
NativeBuffer |
tail(long length) |
byte[] |
toByteArray() |
void |
write(long at,
byte[] source,
int offset,
int length) |
public static NativeBuffer create(long capacity)
public static void pushMemoryPool(int size)
public static void popMemoryPool()
public static NativeBuffer create(byte[] data)
public static NativeBuffer create(String data)
public static NativeBuffer create(byte[] data, int offset, int length)
public NativeBuffer slice(long offset, long length)
public NativeBuffer head(long length)
public NativeBuffer tail(long length)
public void delete()
public long capacity()
public void write(long at, byte[] source, int offset, int length)
public void read(long at, byte[] target, int offset, int length)
public byte[] toByteArray()
public boolean isAllocated()
protected void assertAllocated()
Copyright © 2009–2024 FuseSource, Corp.. All rights reserved.