Example #1
0
 /**
  * Constructor.
  *
  * @param string          $input      An array of parameters from the CLI (in the argv format)
  * @param InputDefinition $definition A InputDefinition instance
  *
  * @deprecated The second argument is deprecated as it does not work (will be removed in 3.0), use 'bind' method instead
  */
 public function __construct($input, InputDefinition $definition = null)
 {
     parent::__construct(array(), null);
     $this->setTokens($this->tokenize($input));
     if (null !== $definition) {
         $this->bind($definition);
     }
 }
 /**
  * Constructor.
  *
  * @param string          $input      An array of parameters from the CLI (in the argv format)
  * @param InputDefinition $definition A InputDefinition instance
  *
  * @deprecated The second argument is deprecated as it does not work (will be removed in 3.0), use 'bind' method instead
  */
 public function __construct($input, InputDefinition $definition = null)
 {
     if ($definition) {
         @trigger_error('The $definition argument of the ' . __METHOD__ . ' method is deprecated and will be removed in 3.0. Set this parameter with the bind() method instead.', E_USER_DEPRECATED);
     }
     parent::__construct(array(), null);
     $this->setTokens($this->tokenize($input));
     if (null !== $definition) {
         $this->bind($definition);
     }
 }
 /**
  * Constructor.
  *
  * @param string     $input An array of parameters from the CLI (in the argv format)
  * @param InputDefinition $definition A InputDefinition instance
  */
 public function __construct($input, InputDefinition $definition = null)
 {
     parent::__construct(array(), $definition);
     $this->tokens = $this->tokenize($input);
 }
Example #4
0
 public static function parse(ArgvInput $input)
 {
     self::$args = $input->getArguments();
     foreach (self::$args as $arg) {
     }
 }
 /**
  * Constructor.
  *
  * @param string          $input      An array of parameters from the CLI (in the argv format)
  *
  * @api
  */
 public function __construct($input)
 {
     parent::__construct(array());
     $this->setTokens($this->tokenize($input));
 }