Toggle navigation
Hot Examples
KO
EN
RU
DE
FR
ES
PT
IT
JP
ZH
KO
PHP
PHP
C#
Java
Go
C++
Python
JS
TS
검색
홈
Cml
Plugin
PHP 클래스 Cml\Plugin
파일 보기
프로젝트 열기: linhecheng/cmlphp
1 사용 예제들
공개 메소드들
메소드
설명
hook
(
string
$hook
,
array
$params
= [] ) :
mixed
执行插件
mount
(
string
$hook
,
array
$params
= [] )
挂载插件到钩子 \Cml\Plugin::mount('hookName', [ function() {//匿名函数 }, '\App\Test\Plugins' => 'run' //对象, '\App\Test\Plugins::run'////静态方法 ]);
메소드 상세
hook()
공개
정적인
메소드
执行插件
public
static
hook
(
string
$hook
,
array
$params
= [] ) :
mixed
$hook
string
插件钩子名称
$params
array
参数
리턴
mixed
mount()
공개
정적인
메소드
挂载插件到钩子 \Cml\Plugin::mount('hookName', [ function() {//匿名函数 }, '\App\Test\Plugins' => 'run' //对象, '\App\Test\Plugins::run'////静态方法 ]);
public
static
mount
(
string
$hook
,
array
$params
= [] )
$hook
string
要挂载的目标钩子
$params
array
相应参数