
public class ODurablePage extends Object
This page has several booked memory areas with following offsets at the beginning:
Developer which will extend this class should use all page memory starting from NEXT_FREE_POSITION offset. All data structures which use this kind of pages should be derived
from ODurableComponent class.
| Modifier and Type | Field and Description |
|---|---|
protected static int |
CRC32_OFFSET |
static int |
MAGIC_NUMBER_OFFSET |
static int |
MAX_PAGE_SIZE_BYTES |
static int |
NEXT_FREE_POSITION |
static int |
WAL_POSITION_OFFSET |
static int |
WAL_SEGMENT_OFFSET |
| Constructor and Description |
|---|
ODurablePage(OCacheEntry cacheEntry) |
| Modifier and Type | Method and Description |
|---|---|
protected <T> T |
deserializeFromDirectMemory(OBinarySerializer<T> binarySerializer,
int offset) |
protected byte[] |
getBinaryValue(int pageOffset,
int valLen) |
protected byte |
getByteValue(int pageOffset) |
OWALChanges |
getChanges() |
protected int |
getIntValue(int pageOffset) |
static OLogSequenceNumber |
getLogSequenceNumber(int offset,
byte[] data)
DO NOT DELETE THIS METHOD IT IS USED IN ENTERPRISE STORAGE
|
static OLogSequenceNumber |
getLogSequenceNumberFromPage(ByteBuffer buffer) |
protected long |
getLongValue(int pageOffset) |
OLogSequenceNumber |
getLsn() |
protected int |
getObjectSizeInDirectMemory(OBinarySerializer binarySerializer,
int offset) |
static void |
getPageData(ByteBuffer buffer,
byte[] data,
int offset,
int length)
DO NOT DELETE THIS METHOD IT IS USED IN ENTERPRISE STORAGE
|
protected short |
getShortValue(int pageOffset) |
protected void |
moveData(int from,
int to,
int len) |
void |
restoreChanges(OWALChanges changes) |
protected int |
setBinaryValue(int pageOffset,
byte[] value) |
protected int |
setByteValue(int pageOffset,
byte value) |
protected int |
setIntValue(int pageOffset,
int value) |
protected int |
setLongValue(int pageOffset,
long value) |
void |
setLsn(OLogSequenceNumber lsn) |
protected int |
setShortValue(int pageOffset,
short value) |
String |
toString() |
public static final int MAGIC_NUMBER_OFFSET
protected static final int CRC32_OFFSET
public static final int WAL_SEGMENT_OFFSET
public static final int WAL_POSITION_OFFSET
public static final int MAX_PAGE_SIZE_BYTES
public static final int NEXT_FREE_POSITION
public ODurablePage(OCacheEntry cacheEntry)
public static OLogSequenceNumber getLogSequenceNumberFromPage(ByteBuffer buffer)
public static void getPageData(ByteBuffer buffer, byte[] data, int offset, int length)
Copies content of page into passed in byte array.
buffer - Buffer from which data will be copieddata - Byte array to which data will be copiedoffset - Offset of data inside pagelength - Length of data to be copiedpublic static OLogSequenceNumber getLogSequenceNumber(int offset, byte[] data)
Get value of LSN from the passed in offset in byte array.
offset - Offset inside of byte array from which LSN value will be read.data - Byte array from which LSN value will be read.protected int getIntValue(int pageOffset)
protected short getShortValue(int pageOffset)
protected long getLongValue(int pageOffset)
protected byte[] getBinaryValue(int pageOffset,
int valLen)
protected int getObjectSizeInDirectMemory(OBinarySerializer binarySerializer, int offset)
protected <T> T deserializeFromDirectMemory(OBinarySerializer<T> binarySerializer, int offset)
protected byte getByteValue(int pageOffset)
protected int setIntValue(int pageOffset,
int value)
protected int setShortValue(int pageOffset,
short value)
protected int setByteValue(int pageOffset,
byte value)
protected int setLongValue(int pageOffset,
long value)
protected int setBinaryValue(int pageOffset,
byte[] value)
protected void moveData(int from,
int to,
int len)
public OWALChanges getChanges()
public void restoreChanges(OWALChanges changes)
public void setLsn(OLogSequenceNumber lsn)
public OLogSequenceNumber getLsn()
Copyright © 2009–2025 OrientDB. All rights reserved.