public function setProvidedOptions($providedOptions = [])
    {
        $this->providedOptions = $providedOptions;

        if (isset($this->providedOptions['png'])) {
            if ($this->getMimeTypeOfSource() == 'image/png') {
                $this->providedOptions = array_merge($this->providedOptions, $this->providedOptions['png']);
//                $this->logLn(print_r($this->providedOptions, true));
            }
        }

        if (isset($this->providedOptions['jpeg'])) {
            if ($this->getMimeTypeOfSource() == 'image/jpeg') {
                $this->providedOptions = array_merge($this->providedOptions, $this->providedOptions['jpeg']);
            }
        }
        // -  Merge $defaultOptions into provided options
        $this->options = array_merge($this->getDefaultOptions(), $this->providedOptions);
    }
public function setProvidedOptions($providedOptions = [])
    {
        $this->providedOptions = $providedOptions;

        if (isset($this->providedOptions['png'])) {
            if ($this->getMimeTypeOfSource() == 'image/png') {
                $this->providedOptions = array_merge($this->providedOptions, $this->providedOptions['png']);
//                $this->logLn(print_r($this->providedOptions, true));
            }
        }

        if (isset($this->providedOptions['jpeg'])) {
            if ($this->getMimeTypeOfSource() == 'image/jpeg') {
                $this->providedOptions = array_merge($this->providedOptions, $this->providedOptions['jpeg']);
            }
        }
        // -  Merge $defaultOptions into provided options
        $this->options = array_merge($this->getDefaultOptions(), $this->providedOptions);
    }
public function setProvidedOptions ( $ providedOptions = [ ] ) { $ this -> providedOptions = $ providedOptions ; if ( isset ( $ this -> providedOptions [ 'png' ] ) ) { if ( $ this -> getMimeTypeOfSource ( ) == 'image/png' ) { $ this -> providedOptions = array_merge ( $ this -> providedOptions , $ this -> providedOptions [ 'png' ] ) ; //                $this->logLn(print_r($this->providedOptions, true)); } } if ( isset ( $ this -> providedOptions [ 'jpeg' ] ) ) { if ( $ this -> getMimeTypeOfSource ( ) == 'image/jpeg' ) { $ this -> providedOptions = array_merge ( $ this -> providedOptions , $ this -> providedOptions [ 'jpeg' ] ) ; } } // -  Merge $defaultOptions into provided options $ this -> options = array_merge ( $ this -> getDefaultOptions ( ) , $ this -> providedOptions ) ; }
Set "provided options"
This also sets the internal options array, by merging in the default options

@param   array $providedOptions (optional)
@return  void
Set provided options This also sets the internal options array by merging in the default options