original_string: protected function _schedule($command, $path, array $arguments, array $options) {
  		$TaskClient = ClassRegistry::init('Task.TaskClient');
  		$task = $TaskClient->add($command, $path, $arguments, $options);
  		if ($task) {
  			$waitFor = empty($options['dependsOn']) ? 'none' : implode(', ', $options['dependsOn']) . ' task(s)';
  			$this->out("Task #{$TaskClient->id} successfuly added, wait for $waitFor");
  		} else {
  			$this->err('Error! Task not added!');
  		}
  		return $task;
  	}
code: protected function _schedule($command, $path, array $arguments, array $options) {
  		$TaskClient = ClassRegistry::init('Task.TaskClient');
  		$task = $TaskClient->add($command, $path, $arguments, $options);
  		if ($task) {
  			$waitFor = empty($options['dependsOn']) ? 'none' : implode(', ', $options['dependsOn']) . ' task(s)';
  			$this->out("Task #{$TaskClient->id} successfuly added, wait for $waitFor");
  		} else {
  			$this->err('Error! Task not added!');
  		}
  		return $task;
  	}
code_tokens: protected function _schedule ( $ command , $ path , array $ arguments , array $ options ) { $ TaskClient = ClassRegistry :: init ( 'Task.TaskClient' ) ; $ task = $ TaskClient -> add ( $ command , $ path , $ arguments , $ options ) ; if ( $ task ) { $ waitFor = empty ( $ options [ 'dependsOn' ] ) ? 'none' : implode ( ', ' , $ options [ 'dependsOn' ] ) . ' task(s)' ; $ this -> out ( "Task #{$TaskClient->id} successfuly added, wait for $waitFor" ) ; } else { $ this -> err ( 'Error! Task not added!' ) ; } return $ task ; }
docstring: Adds script to sceduler
  
  @param string $command
  @param string $path
  @param array $arguments
  @param array $options
docstring_tokens: Adds script to sceduler