protected function setOptions($options)
    {
        if (!$options instanceof OptionsInterface) {
            $options = is_array($options) ? $options : [];
            $options = new Options($options);
        }

        $this->options = $options;
    }
protected function setOptions($options)
    {
        if (!$options instanceof OptionsInterface) {
            $options = is_array($options) ? $options : [];
            $options = new Options($options);
        }

        $this->options = $options;
    }
protected function setOptions ( $ options ) { if ( ! $ options instanceof OptionsInterface ) { $ options = is_array ( $ options ) ? $ options : [ ] ; $ options = new Options ( $ options ) ; } $ this -> options = $ options ; }
Sets the given options.

@param array|Options $options options to set
Sets the given options .