示例#1
0
 public function Bind()
 {
     Event::Add('OnTaskReceived', [$this, 'OnTaskReceived']);
     Event::Add("OnTaskFinished", [$this, 'OnTaskFinished']);
     Event::Add('OnFinish', [$this, 'OnFinish']);
     Event::Add('OnTaskSent', [$this, 'OnTaskSent']);
     Event::Add('OnRequest', [$this, 'OnRequest']);
 }
示例#2
0
 public function Bind()
 {
     Event::Add(['OnClose'], [$this, '']);
 }
示例#3
0
 /**
  * 启动应用程序
  */
 public function Start()
 {
     static::SetInstance($this);
     $this->bindBaseClass();
     $this->AutoRegistry("Application.php");
     $this->bindCoreAliases();
     Event::Add('OnMasterStart', [$this, 'RecordPID']);
     Bootstrapper::Boot();
 }