/** * @param array $nodes */ public function initialize(array $nodes) { parent::initialize($nodes); $this->validateNodes(); $this->buildProcessingNodes(); $this->prepareForProcessing(); }
/** * @param array $nodes */ public function initialize(array $nodes) { if (!extension_loaded('pthreads')) { throw new RuntimeException('Cannot use the Parallel processor without the pthreads extension.'); } parent::initialize($nodes); $this->validateNodes(); $this->buildProcessingNodes(); $this->prepareForProcessing(); }
/** * @return \tomzx\Dataflow\Result */ public function process() { return $this->processor->process(func_get_args()); }