class Util

internal  
 

Methods

static array
arrayWrap(mixed $value)

If the given value is not an array and not null, wrap it in one.

static mixed
unwrapIfClosure(mixed $value, mixed ...$args)

Return the default value of the given value.

static string|null
getParameterClassName(ReflectionParameter $parameter)

Get the class name of the given parameter's type, if possible.

static ReflectionAttribute|null
getContextualAttributeFromDependency(ReflectionParameter $dependency)

Get a contextual attribute from a dependency.

Details

at line 23
static array arrayWrap(mixed $value)

If the given value is not an array and not null, wrap it in one.

From Arr::wrap() in Hypervel\Support.

Parameters

mixed $value

Return Value

array

at line 37
static mixed unwrapIfClosure(mixed $value, mixed ...$args)

Return the default value of the given value.

From global value() helper in Hypervel\Support.

Parameters

mixed $value
mixed ...$args

Return Value

mixed

at line 47
static string|null getParameterClassName(ReflectionParameter $parameter)

Get the class name of the given parameter's type, if possible.

From Reflector::getParameterClassName() in Hypervel\Support.

Parameters

ReflectionParameter $parameter

Return Value

string|null

at line 73
static ReflectionAttribute|null getContextualAttributeFromDependency(ReflectionParameter $dependency)

Get a contextual attribute from a dependency.

Parameters

ReflectionParameter $dependency

Return Value

ReflectionAttribute|null