class FileJournal extends Object implements IJournal

Btree+ based file journal.

Constants

FILE

Filename with journal

FILE_MAGIC

4 bytes file header magic (btfj)

INDEX_MAGIC

4 bytes index node magic (inde)

DATA_MAGIC

4 bytes data node magic (data)

NODE_SIZE

Node size in bytes

BITROT

Bit rotation for saving data into nodes. BITROT = log2(NODE_SIZE)

HEADER_SIZE

Header size in bytes

INT32_SIZE

Size of 32 bit integer in bytes. INT32_SIZE = 32 / 8 :-)

INFO

TYPE

IS_LEAF

PREV_NODE

END

MAX

INDEX_DATA

LAST_INDEX

TAGS

PRIORITY

ENTRIES

DATA

KEY

DELETED

Properties

static $debug

Debug mode, only for testing purposes

Methods

__construct($dir)

No description

void
__destruct()

No description

void
write($key, array $dependencies)

Writes entry information into the journal.

array
clean(array $conditions)

Cleans entries from journal.

Details

at line 103
__construct($dir)

No description

Parameters

$dir

at line 112
void __destruct()

No description

Return Value

void

at line 129
void write($key, array $dependencies)

Writes entry information into the journal.

Parameters

$key
array $dependencies

Return Value

void

at line 236
array clean(array $conditions)

Cleans entries from journal.

Parameters

array $conditions

Return Value

array

of removed items or NULL when performing a full cleanup