Flow PHP

Parameter

Read onlyYes
FinalYes

Every as*() reader separates the two axes: a genuine NULL flowing through is not an error and propagates (or takes the reader's null-input default), while a non-null value that cannot coerce throws, naming its row - optional() is the door for pipelines that want the old silent tolerance.

Methods

__construct()  : mixed
arraysOf()  : array<int, array<string|int, mixed>|null>
asArrays()  : array<int, array<string|int, mixed>|null>
asBooleans()  : array<int, bool|null>
asEnums()  : array<int, T|null>
asInstancesOf()  : array<int, T|null>
asIntegerColumn()  : Column
asInts()  : ($default is null ? list : list)
$default applies to a NULL input only - a malformed value always throws.
asListsOfObjects()  : array<int, array<int, object>|null>
asNumberColumn()  : Column
asNumbers()  : ($default is null ? list : list)
$default applies to a NULL input only - a malformed value always throws.
asStrings()  : ($default is null ? list : list)
$default applies to a NULL input only - a malformed value always throws.
asTypes()  : array<int, T|null>
checked()  : array<int, mixed>
values()  : array<int, mixed>

Methods

__construct()

public __construct(mixed $function) : mixed
Parameters
$function : mixed

arraysOf()

public arraysOf(Column $column) : array<int, array<string|int, mixed>|null>
Parameters
$column : Column
Return values
array<int, array<string|int, mixed>|null>

asArrays()

public asArrays(Rows $rows, Backend $backend) : array<int, array<string|int, mixed>|null>
Parameters
$rows : Rows
$backend : Backend
Return values
array<int, array<string|int, mixed>|null>

asBooleans()

public asBooleans(Rows $rows, Backend $backend) : array<int, bool|null>
Parameters
$rows : Rows
$backend : Backend
Return values
array<int, bool|null>

asEnums()

public asEnums(Rows $rows, Backend $backend, T> $enumClass) : array<int, T|null>
Parameters
$rows : Rows
$backend : Backend
$enumClass : T>
Tags
template
Return values
array<int, T|null>

asInstancesOf()

public asInstancesOf(Rows $rows, Backend $backend, T> $class) : array<int, T|null>
Parameters
$rows : Rows
$backend : Backend
$class : T>
Tags
template
Return values
array<int, T|null>

asInts()

$default applies to a NULL input only - a malformed value always throws.

public asInts(Rows $rows, Backend $backend[, int|null $default = null ]) : ($default is null ? list : list)
Parameters
$rows : Rows
$backend : Backend
$default : int|null = null
Return values
($default is null ? list : list)

asListsOfObjects()

public asListsOfObjects(Rows $rows, Backend $backend, class-string $class) : array<int, array<int, object>|null>
Parameters
$rows : Rows
$backend : Backend
$class : class-string
Return values
array<int, array<int, object>|null>

asNumbers()

$default applies to a NULL input only - a malformed value always throws.

public asNumbers(Rows $rows, Backend $backend[, int|float|null $default = null ]) : ($default is null ? list : list)
Parameters
$rows : Rows
$backend : Backend
$default : int|float|null = null
Return values
($default is null ? list : list)

asStrings()

$default applies to a NULL input only - a malformed value always throws.

public asStrings(Rows $rows, Backend $backend[, string|null $default = null ]) : ($default is null ? list : list)
Parameters
$rows : Rows
$backend : Backend
$default : string|null = null
Return values
($default is null ? list : list)

asTypes()

public asTypes(Rows $rows, Backend $backend, Type<string|int, T> ...$types) : array<int, T|null>
Parameters
$rows : Rows
$backend : Backend
$types : Type<string|int, T>
Tags
template
Return values
array<int, T|null>

checked()

public checked(array<int, mixed> $values, Type<string|int, mixed> $type) : array<int, mixed>
Parameters
$values : array<int, mixed>
$type : Type<string|int, mixed>
Return values
array<int, mixed>
On this page

Search results