protected final function validate()
    {
        if (isset($this->pid) && !isset($this->resource)) {
            throw new LogicException('Process already closed.', static::ERR_COMPLETED);
        } elseif ($this->running) {
            throw new LogicException('Process already running.', static::ERR_RUNNING);
        }

        $this->command->validate();
    }
protected final function validate()
    {
        if (isset($this->pid) && !isset($this->resource)) {
            throw new LogicException('Process already closed.', static::ERR_COMPLETED);
        } elseif ($this->running) {
            throw new LogicException('Process already running.', static::ERR_RUNNING);
        }

        $this->command->validate();
    }
protected final function validate ( ) { if ( isset ( $ this -> pid ) && ! isset ( $ this -> resource ) ) { throw new LogicException ( 'Process already closed.' , static :: ERR_COMPLETED ) ; } elseif ( $ this -> running ) { throw new LogicException ( 'Process already running.' , static :: ERR_RUNNING ) ; } $ this -> command -> validate ( ) ; }
Validate the process can be run.

@throws LogicException
Validate the process can be run .