protected function buildArguments(array $options = array())
    {
        $arguments = array();

        foreach ($options as $key => $value) {
            // Validate value and format it
            if ($value === false or is_int($key)) {
                continue;
            }

            $arguments[] = "--$key";

            if (is_array($value)) {
                $arguments = array_merge($arguments, $this->buildArrayArguments($value));
            } elseif ($value !== true) {
                $arguments[] = $value;
            }
        }

        return $arguments;
    }
protected function buildArguments(array $options = array())
    {
        $arguments = array();

        foreach ($options as $key => $value) {
            // Validate value and format it
            if ($value === false or is_int($key)) {
                continue;
            }

            $arguments[] = "--$key";

            if (is_array($value)) {
                $arguments = array_merge($arguments, $this->buildArrayArguments($value));
            } elseif ($value !== true) {
                $arguments[] = $value;
            }
        }

        return $arguments;
    }
protected function buildArguments ( array $ options = array ( ) ) { $ arguments = array ( ) ; foreach ( $ options as $ key => $ value ) { // Validate value and format it if ( $ value === false or is_int ( $ key ) ) { continue ; } $ arguments [ ] = "--$key" ; if ( is_array ( $ value ) ) { $ arguments = array_merge ( $ arguments , $ this -> buildArrayArguments ( $ value ) ) ; } elseif ( $ value !== true ) { $ arguments [ ] = $ value ; } } return $ arguments ; }
Build command line options from array

@param  array  $options      Input parameters
@param  bool   $recursive    Should NEVER been set manually
@return string               Argument string
Build command line options from array