typing extends facade
Facade for local_middag\framework\support\typing.
Tags
Table of Contents
Methods
- cast_array_of_ints() : array<string|int, mixed>
- cast_array_of_strings() : array<string|int, mixed>
- get_facade_accessor() : string
- Return the service accessor key for this facade.
- is_numeric_string() : bool
- normalize() : int|null
- normalize_id() : int|null
- normalize_id_or_zero() : int
- normalize_record() : stdClass
- to_bool() : bool
- to_float() : float|null
- to_int() : int|null
- to_positive_int() : int|null
- to_string() : string
Methods
cast_array_of_ints()
public
static cast_array_of_ints(array<string|int, mixed> $array) : array<string|int, mixed>
Parameters
- $array : array<string|int, mixed>
Return values
array<string|int, mixed>cast_array_of_strings()
public
static cast_array_of_strings(array<string|int, mixed> $array) : array<string|int, mixed>
Parameters
- $array : array<string|int, mixed>
Return values
array<string|int, mixed>get_facade_accessor()
Return the service accessor key for this facade.
public
static get_facade_accessor() : string
Return values
stringis_numeric_string()
public
static is_numeric_string(mixed $value) : bool
Parameters
- $value : mixed
Return values
boolnormalize()
public
static normalize(mixed $value) : int|null
Parameters
- $value : mixed
Return values
int|nullnormalize_id()
public
static normalize_id(mixed $value) : int|null
Parameters
- $value : mixed
Return values
int|nullnormalize_id_or_zero()
public
static normalize_id_or_zero(mixed $value) : int
Parameters
- $value : mixed
Return values
intnormalize_record()
public
static normalize_record(stdClass|array<string|int, mixed> $record, array<string|int, mixed> $spec) : stdClass
Parameters
- $record : stdClass|array<string|int, mixed>
- $spec : array<string|int, mixed>
Return values
stdClassto_bool()
public
static to_bool(mixed $value) : bool
Parameters
- $value : mixed
Return values
boolto_float()
public
static to_float(mixed $value) : float|null
Parameters
- $value : mixed
Return values
float|nullto_int()
public
static to_int(mixed $value) : int|null
Parameters
- $value : mixed
Return values
int|nullto_positive_int()
public
static to_positive_int(mixed $value) : int|null
Parameters
- $value : mixed
Return values
int|nullto_string()
public
static to_string(mixed $value) : string
Parameters
- $value : mixed