cvs: pear /XML_DB_eXist/eXist SOAP.class.php
| From: | Benjamin Muskalla | Date: | Thu, 19 Oct 2006 21:12:31 +0000 |
| Subject: | cvs: pear /XML_DB_eXist/eXist SOAP.class.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-42656@lists.php.net to get a copy of this message | ||
bmuskalla Thu Oct 19 21:12:31 2006 UTC
Modified files:
/pear/XML_DB_eXist/eXist SOAP.class.php
Log:
Bug #8916: Added new param to the connect() function of SOAP driver to have the possibility to
pass additional parameters to the SoapClient instance (thanks Stephane Gully)
http://cvs.php.net/viewvc.cgi/pear/XML_DB_eXist/eXist/SOAP.class.php?r1=1.1.1.1&r2=1.2&diff_format=u
Index: pear/XML_DB_eXist/eXist/SOAP.class.php
diff -u pear/XML_DB_eXist/eXist/SOAP.class.php:1.1.1.1 pear/XML_DB_eXist/eXist/SOAP.class.php:1.2
--- pear/XML_DB_eXist/eXist/SOAP.class.php:1.1.1.1 Sun Jun 4 02:49:44 2006
+++ pear/XML_DB_eXist/eXist/SOAP.class.php Thu Oct 19 21:12:31 2006
@@ -89,6 +89,7 @@
*
* @param string $username the username to connect
* @param string $password the password of the user
+ * @param array $options options to forward to the SoapClient object (ex: proxy_host, proxy_port
...)
*
* @return void
* @since 0.1
@@ -96,14 +97,18 @@
* @throws Exception
* @author Benjamin Muskalla <b.muskalla@gmx.net>
*/
- public function connect($username = 'guest', $password = 'guest')
+ public function connect($username = 'guest', $password = 'guest', $options =
array())
{
- /* initialise the SOAPClient and load wsdl file */
- $this->soap = new SoapClient($this->wsdl, array('exceptions' => true));
- $this->soapAdmin = new SoapClient($this->wsdlAdmin,
- array('exceptions' => true));
+ /* initialize options */
+ $options = array_merge($options, array("exceptions" => true));
+
+ /* initialize the SOAPClient and load wsdl file */
+ $this->soap = new SoapClient($this->wsdl, $options);
+ $this->soapAdmin = new SoapClient($this->wsdlAdmin, $options);
+
$session = $this->soap->connect(array('userId' => $username,
'password' => $password));
+
$this->session = $session->connectReturn;
}