public function handleInit(Control $control, Context $context)
    {
        if (! $context->pidfile instanceof Pidfile) {
            $context->pidfile = new Pidfile($control, $this->getOption('name'), $this->getOption('lock_dir'));
        }
        $context->isRunning = $context->pidfile->isActive();
        $context->processId = $context->pidfile->getProcessId();
    }
public function handleInit(Control $control, Context $context)
    {
        if (! $context->pidfile instanceof Pidfile) {
            $context->pidfile = new Pidfile($control, $this->getOption('name'), $this->getOption('lock_dir'));
        }
        $context->isRunning = $context->pidfile->isActive();
        $context->processId = $context->pidfile->getProcessId();
    }
public function handleInit ( Control $ control , Context $ context ) { if ( ! $ context -> pidfile instanceof Pidfile ) { $ context -> pidfile = new Pidfile ( $ control , $ this -> getOption ( 'name' ) , $ this -> getOption ( 'lock_dir' ) ) ; } $ context -> isRunning = $ context -> pidfile -> isActive ( ) ; $ context -> processId = $ context -> pidfile -> getProcessId ( ) ; }
Default trigger for EVENT_INIT.

@param Control $control
@param Context $context
Default trigger for EVENT_INIT .