public function getOptions($includeDefaults = true)
    {
        $options = $this->options;

        if ($includeDefaults) {
            foreach ($this->format->getOptions() as $option) {
                $name = $option->getLongName();

                if (!array_key_exists($name, $options)) {
                    $options[$name] = $option->acceptsValue() ? $option->getDefaultValue() : false;
                }
            }
        }

        return $options;
    }
public function getOptions($includeDefaults = true)
    {
        $options = $this->options;

        if ($includeDefaults) {
            foreach ($this->format->getOptions() as $option) {
                $name = $option->getLongName();

                if (!array_key_exists($name, $options)) {
                    $options[$name] = $option->acceptsValue() ? $option->getDefaultValue() : false;
                }
            }
        }

        return $options;
    }
public function getOptions ( $ includeDefaults = true ) { $ options = $ this -> options ; if ( $ includeDefaults ) { foreach ( $ this -> format -> getOptions ( ) as $ option ) { $ name = $ option -> getLongName ( ) ; if ( ! array_key_exists ( $ name , $ options ) ) { $ options [ $ name ] = $ option -> acceptsValue ( ) ? $ option -> getDefaultValue ( ) : false ; } } } return $ options ; }
Returns all options.

By default, this method also includes the default values set for options
with values. You can disable this behavior by passing `false` for
`$includeDefaults`.

@param bool $includeDefaults Whether to return the default values for
options that were not set.

@return array The option values and `true`/`false` for options without
values.

@see getOption()
Returns all options .