Flow PHP

PhpBackend implements Backend, Describable

Read onlyYes
FinalYes

Interfaces

Backend
Describable

Methods

__construct()  : mixed
add()  : Column
adopt()  : Column
The same values in this backend's storage: $column itself when this backend owns it, otherwise one copy through builder($definition)->appendTake(). For producers that build columns outside the configured backend.
allocatedBytes()  : int
Bytes this backend holds outside PHP's memory manager (invisible to memory_get_usage() and memory_limit).
builder()  : ColumnBuilder
compare()  : Column
constant()  : Column
$value is logical or raw and is cast once through the Definition exactly like ColumnBuilder::append().
decode()  : Column
Child node lengths and null counts are derived from the buffers, so only the top node travels.
decodeFrame()  : Rows
A Floe BATCH frame body as Rows under $schema. $codec decodes the buffers stored with a length prefix (a prefix of -1 is a raw buffer). The refusals are the frame's: truncated directory, counts other than the schema's, a column of another row count, a buffer outside the area, a column whose buffers the backend refuses.
describe()  : null|Description
encodeFrame()  : string
$rows as one Floe BATCH frame body: the directory, then every column's buffers in schema order, each stored raw (prefix -1) or through $codec with its raw length as prefix when that is shorter, 8-byte padded. The exact bytes decodeFrame() reads back.
fromDescription()  : static
groupedCounts()  : GroupedCounts
groupedTotals()  : GroupedTotals
groupTable()  : GroupTable
isNotNull()  : Column
isNull()  : Column
modulo()  : Column
multiply()  : Column
sort()  : Rows
subtract()  : Column

Methods

adopt()

The same values in this backend's storage: $column itself when this backend owns it, otherwise one copy through builder($definition)->appendTake(). For producers that build columns outside the configured backend.

public adopt(Definition $definition, Column $column) : Column
Parameters
$definition : Definition
$column : Column
Return values
Column

allocatedBytes()

Bytes this backend holds outside PHP's memory manager (invisible to memory_get_usage() and memory_limit).

public allocatedBytes() : int
Return values
int

compare()

public compare(Column $left, Operator $operator, Column $right, string $leftName, string $rightName) : Column
Parameters
$left : Column
$operator : Operator
$right : Column
$leftName : string
$rightName : string
Return values
Column

constant()

$value is logical or raw and is cast once through the Definition exactly like ColumnBuilder::append().

public constant(Definition $definition, mixed $value, int $count) : Column
Parameters
$definition : Definition
$value : mixed
$count : int
Return values
Column

decode()

Child node lengths and null counts are derived from the buffers, so only the top node travels.

public decode(Definition $definition, array<string|int, mixed> $buffers, int $count, int $nullCount) : Column
Parameters
$definition : Definition
$buffers : array<string|int, mixed>

the column's subtree buffers as Column::encode() produced them ('' = omitted validity)

$count : int
$nullCount : int
Return values
Column

decodeFrame()

A Floe BATCH frame body as Rows under $schema. $codec decodes the buffers stored with a length prefix (a prefix of -1 is a raw buffer). The refusals are the frame's: truncated directory, counts other than the schema's, a column of another row count, a buffer outside the area, a column whose buffers the backend refuses.

public decodeFrame(string $body, Schema $schema, Codec $codec) : Rows
Parameters
$body : string
$schema : Schema
$codec : Codec
Return values
Rows

describe()

public describe() : null|Description
Return values
null|Description —

null when this instance cannot cross a process boundary (a live client, a custom collaborator)

encodeFrame()

$rows as one Floe BATCH frame body: the directory, then every column's buffers in schema order, each stored raw (prefix -1) or through $codec with its raw length as prefix when that is shorter, 8-byte padded. The exact bytes decodeFrame() reads back.

public encodeFrame(Rows $rows, Codec $codec) : string
Parameters
$rows : Rows
$codec : Codec
Return values
string

fromDescription()

public static fromDescription(array<string|int, mixed> $data, Rebuild $rebuild) : static
Parameters
$data : array<string|int, mixed>
$rebuild : Rebuild
Return values
static

sort()

public sort(Rows $rows, array<string|int, mixed> $columns) : Rows
Parameters
$rows : Rows
$columns : array<string|int, mixed>
Return values
Rows
On this page

Search results