mobile_import.php 429 B

12345678910111213141516171819
  1. <?php
  2. use Workerman\Lib\Timer;
  3. use Workerman\Worker as WO;
  4. class MobileImportWork extends Com{
  5. public static function run(){
  6. $work=self::newWorker();
  7. $work->onWorkerStart=function (WO $worker){
  8. Timer::add(3,function ()use ($worker){
  9. self::import();
  10. });
  11. };
  12. }
  13. public static function import(){
  14. throw_user('aaaa');
  15. }
  16. }
  17. MobileImportWork::run();