コード例 #1
0
ファイル: ZendHttp.php プロジェクト: lhess/solarium
 /**
  * Set options
  *
  * Overrides any existing values.
  *
  * If the options array has an 'options' entry it is forwarded to the
  * Zend_Http_Client. See the Zend_Http_Clientdocs for the many config
  * options available.
  *
  * The $options param should be an array or an object that has a toArray
  * method, like Zend_Config
  *
  * @param  array|object $options
  * @param  boolean      $overwrite
  * @return self         Provides fluent interface
  */
 public function setOptions($options, $overwrite = false)
 {
     parent::setOptions($options, $overwrite);
     // forward options to zendHttp instance
     if (null !== $this->zendHttp) {
         // forward timeout setting
         $adapterOptions = array();
         // forward adapter options if available
         if (isset($this->options['options'])) {
             $adapterOptions = array_merge($adapterOptions, $this->options['options']);
         }
         $this->zendHttp->setConfig($adapterOptions);
     }
     return $this;
 }