web/lib/Zend/Soap/Client.php
changeset 1230 68c69c656a2c
parent 807 877f952ae2bd
--- a/web/lib/Zend/Soap/Client.php	Thu May 07 15:10:09 2015 +0200
+++ b/web/lib/Zend/Soap/Client.php	Thu May 07 15:16:02 2015 +0200
@@ -15,9 +15,9 @@
  * @category   Zend
  * @package    Zend_Soap
  * @subpackage Client
- * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
+ * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  * @license    http://framework.zend.com/license/new-bsd     New BSD License
- * @version    $Id: Client.php 24593 2012-01-05 20:35:02Z matthew $
+ * @version    $Id$
  */
 
 /**
@@ -41,7 +41,7 @@
  * @category   Zend
  * @package    Zend_Soap
  * @subpackage Client
- * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
+ * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  * @license    http://framework.zend.com/license/new-bsd     New BSD License
  */
 class Zend_Soap_Client
@@ -89,6 +89,7 @@
     protected $_features            = null;
     protected $_cache_wsdl          = null;
     protected $_user_agent          = null;
+    protected $_exceptions          = null;
 
     /**
      * WSDL used to access server
@@ -268,6 +269,9 @@
                 case 'user_agent':
                     $this->setUserAgent($value);
                     break;
+                case 'exceptions':
+                    $this->setExceptions($value);
+                    break;
 
                 // Not used now
                 // case 'connection_timeout':
@@ -315,13 +319,14 @@
         $options['cache_wsdl']     = $this->getWsdlCache();
         $options['features']       = $this->getSoapFeatures();
         $options['user_agent']     = $this->getUserAgent();
+        $options['exceptions']     = $this->getExceptions();
 
         foreach ($options as $key => $value) {
             /*
              * ugly hack as I don't know if checking for '=== null'
              * breaks some other option
              */
-            if (in_array($key, array('user_agent', 'cache_wsdl', 'compression'))) {
+            if (in_array($key, array('user_agent', 'cache_wsdl', 'compression', 'exceptions'))) {
                 if ($value === null) {
                     unset($options[$key]);
                 }
@@ -909,6 +914,39 @@
     }
 
     /**
+     * Set the exceptions option
+     *
+     * The exceptions option is a boolean value defining whether soap errors
+     * throw exceptions.
+     *
+     * @see http://php.net/manual/soapclient.soapclient.php#refsect1-soapclient.soapclient-parameters
+     *
+     * @param bool $exceptions
+     * @return $this
+     */
+    public function setExceptions($exceptions)
+    {
+        $this->_exceptions = (bool) $exceptions;
+
+        return $this;
+    }
+
+    /**
+     * Get the exceptions option
+     *
+     * The exceptions option is a boolean value defining whether soap errors
+     * throw exceptions.
+     *
+     * @see http://php.net/manual/soapclient.soapclient.php#refsect1-soapclient.soapclient-parameters
+     *
+     * @return bool|null
+     */
+    public function getExceptions()
+    {
+        return $this->_exceptions;
+    }
+
+    /**
      * Retrieve request XML
      *
      * @return string