public class Memory
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected long |
peer |
| Modifier | Constructor and Description |
|---|---|
protected |
Memory(long bytes) |
| Modifier and Type | Method and Description |
|---|---|
static Memory |
allocate(long bytes) |
boolean |
equals(java.lang.Object o) |
void |
free() |
byte |
getByte(long offset) |
void |
getBytes(long memoryOffset,
byte[] buffer,
int bufferOffset,
int count)
Transfers count bytes from Memory starting at memoryOffset to buffer starting at bufferOffset
|
long |
getLong(long offset) |
void |
setByte(long offset,
byte b) |
void |
setBytes(long memoryOffset,
byte[] buffer,
int bufferOffset,
int count)
Transfers count bytes from buffer to Memory
|
void |
setLong(long offset,
long l) |
void |
setMemory(long offset,
long bytes,
byte b) |
long |
size() |
public static Memory allocate(long bytes)
public void setByte(long offset,
byte b)
public void setMemory(long offset,
long bytes,
byte b)
public void setLong(long offset,
long l)
public void setBytes(long memoryOffset,
byte[] buffer,
int bufferOffset,
int count)
memoryOffset - start offset in the memorybuffer - the data bufferbufferOffset - start offset of the buffercount - number of bytes to transferpublic byte getByte(long offset)
public long getLong(long offset)
public void getBytes(long memoryOffset,
byte[] buffer,
int bufferOffset,
int count)
memoryOffset - start offset in the memorybuffer - the data bufferbufferOffset - start offset of the buffercount - number of bytes to transferpublic void free()
public long size()
public boolean equals(java.lang.Object o)
equals in class java.lang.ObjectCopyright © 2014 The Apache Software Foundation