GC_Hook::offsetSet()
最后更新于:2021-11-27 21:29:30
GC_Hook::offsetSet( mixed$offset, mixed$value)Sets a value at a specified offset.
参数
- $offset
-
(mixed) (Required) The offset to assign the value to.
- $value
-
(mixed) (Required) The value to set.
源文件
文件: gc-includes/class-gc-hook.php
public function offsetSet( $offset, $value ) {
if ( is_null( $offset ) ) {
$this->callbacks[] = $value;
} else {
$this->callbacks[ $offset ] = $value;
}
}