Helper
class Helper (View source)
Methods
Parse version format
Convert string to ASCII
Capitalize words using hyphen or a custom delimiter.
Read array or object by path using dot
Equivalent to is_iterable
from PHP-7.1.0+
Check if array is sequential, like ['foo', 'bar']
Check if array is associative, like [ 'bar' => foo', 'baz' => 'bar']
Check if array is associative, like [ 'bar' => foo', 'baz' => 'bar']
Details
at line 20
static stdClass|null
parseVersion(string $version)
Parse version format
at line 44
static string
toAscii(string $text)
Convert string to ASCII
at line 58
static string
capitalize(string $text, string $delimiter = '-', string $glue = '')
Capitalize words using hyphen or a custom delimiter.
at line 71
static mixed
extract(string $path, array|stdClass $items, mixed $alternative = null)
Read array or object by path using dot
at line 94
static bool
iterable(mixed $obj)
Equivalent to is_iterable
from PHP-7.1.0+
at line 105
static bool
seq(mixed $array)
Check if array is sequential, like ['foo', 'bar']
at line 121
static bool
assoc(mixed $array)
Check if array is associative, like [ 'bar' => foo', 'baz' => 'bar']
at line 133
static void
ksort(array $array, int $flags = \SORT_REGULAR)
Check if array is associative, like [ 'bar' => foo', 'baz' => 'bar']