PHP Class Toplan\PhpSms\Util

Datei anzeigen Open project: toplan/phpsms Class Usage Examples

Public Methods

Method Description
operateArray ( array &$arr, mixed $key, mixed $value = null, mixed $getDefault = null, Closure $setAction = null, boolean $override = false, Closure | null $beforeOverride = null, boolean $isSet = false ) : mixed 对数组进行赋值/取值操作
pullFromArrayByKey ( array &$options, integer | string $key ) : mixed Pull the value from the specified array by key.

Method Details

operateArray() public static method

对数组进行赋值/取值操作
public static operateArray ( array &$arr, mixed $key, mixed $value = null, mixed $getDefault = null, Closure $setAction = null, boolean $override = false, Closure | null $beforeOverride = null, boolean $isSet = false ) : mixed
$arr array
$key mixed
$value mixed
$getDefault mixed
$setAction Closure
$override boolean
$beforeOverride Closure | null
$isSet boolean
return mixed

pullFromArrayByKey() public static method

Pull the value from the specified array by key.
public static pullFromArrayByKey ( array &$options, integer | string $key ) : mixed
$options array
$key integer | string
return mixed