cvs: pear /SOAP Client.php Disco.php /SOAP/example disco_server.php

From: Date: Sun, 20 Apr 2003 23:05:28 +0000
Subject: cvs: pear /SOAP Client.php Disco.php /SOAP/example disco_server.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-9998@lists.php.net to get a copy of this message
shane Sun Apr 20 19:05:28 2003 EDT Modified files: /pear/SOAP Client.php Disco.php /pear/SOAP/example disco_server.php Log: a couple minor disco fixes allow client setOpt to set regular options that do not have categories Index: pear/SOAP/Client.php diff -u pear/SOAP/Client.php:1.56 pear/SOAP/Client.php:1.57 --- pear/SOAP/Client.php:1.56 Sun Apr 13 21:42:04 2003 +++ pear/SOAP/Client.php Sun Apr 20 19:05:28 2003 @@ -17,7 +17,7 @@ // | Authors: Dietrich Ayala <dietrich@ganx4.com> Original Author | // +----------------------------------------------------------------------+ // -// $Id: Client.php,v 1.56 2003/04/14 01:42:04 shane Exp $ +// $Id: Client.php,v 1.57 2003/04/20 23:05:28 shane Exp $ // require_once 'SOAP/Value.php'; @@ -38,7 +38,7 @@ * originaly based on SOAPx4 by Dietrich Ayala http://dietrich.ganx4.com/soapx4 * * @access public - * @version $Id: Client.php,v 1.56 2003/04/14 01:42:04 shane Exp $ + * @version $Id: Client.php,v 1.57 2003/04/20 23:05:28 shane Exp $ * @package SOAP::Client * @author Shane Caraveo <shane@php.net> Conversion to PEAR and updates * @author Stig Bakken <ssb@fast.no> Conversion to PEAR @@ -304,10 +304,14 @@ * @return void * @see SOAP_Client::__optionCategories */ - function setOpt($category, $option, $value) + function setOpt($category, $option, $value=NULL) { - if (in_array($category, $this->__optionCategories)) { - $this->__options[$category][$option] = $value; + if ($value) { + if (in_array($category, $this->__optionCategories)) { + $this->__options[$category][$option] = $value; + } + } else { + $this->__options[$category] = $option; } } Index: pear/SOAP/Disco.php diff -u pear/SOAP/Disco.php:1.3 pear/SOAP/Disco.php:1.4 --- pear/SOAP/Disco.php:1.3 Thu Apr 17 04:05:37 2003 +++ pear/SOAP/Disco.php Sun Apr 20 19:05:28 2003 @@ -16,7 +16,7 @@ // | Author: Dmitri Vinogradov <dimitri@vinogradov.de> | // +----------------------------------------------------------------------+ // -// $Id: Disco.php,v 1.3 2003/04/17 08:05:37 shane Exp $ +// $Id: Disco.php,v 1.4 2003/04/20 23:05:28 shane Exp $ require_once 'SOAP/Base.php'; @@ -81,7 +81,7 @@ { # WSDL if (is_array($this->soap_server->_namespaces)) { - # need to get: typens, xsd & soapenc + # need to get: typens, xsd & SOAP-ENC $flipped = array_flip($this->soap_server->_namespaces); $this->namespaces[$this->_service_ns] = 'tns'; $this->namespaces[$flipped['xsd']] = 'xsd'; @@ -146,7 +146,8 @@ $this->addMethodsFromMap($object->__dispatch_map,$namespace,get_class($object)); } } - $this->addMethodsFromMap($server->dispatch_map,$namespace); + if (isset($server->dispatch_map)) + $this->addMethodsFromMap($server->dispatch_map,$namespace); # generate wsdl @@ -191,10 +192,10 @@ $el['attr']['type'] = $_vartypens . ':' . $_vartype; } else { $ctype['complexContent']['attr'] = ''; - $ctype['complexContent']['restriction']['attr']['base'] = 'soapenc:Array'; + $ctype['complexContent']['restriction']['attr']['base'] = 'SOAP-ENC:Array'; foreach ($_vartype as $array_var => $array_type) { list($_vartypens,$_vartype) = $this->_getTypeNs($array_type); - $ctype['complexContent']['restriction']['attribute']['attr']['ref'] = 'soapenc:arrayType'; + $ctype['complexContent']['restriction']['attribute']['attr']['ref'] = 'SOAP-ENC:arrayType'; $ctype['complexContent']['restriction']['attribute']['attr']['wsdl:arrayType'] = $_vartypens . ':' . $_vartype . '[]'; } } Index: pear/SOAP/example/disco_server.php diff -u pear/SOAP/example/disco_server.php:1.2 pear/SOAP/example/disco_server.php:1.3 --- pear/SOAP/example/disco_server.php:1.2 Sun Apr 13 17:38:59 2003 +++ pear/SOAP/example/disco_server.php Sun Apr 20 19:05:28 2003 @@ -16,7 +16,7 @@ // | Author: Dmitri Vinogradov <dimitri@vinogradov.de> | // +----------------------------------------------------------------------+ // -// $Id: disco_server.php,v 1.2 2003/04/13 21:38:59 shane Exp $ +// $Id: disco_server.php,v 1.3 2003/04/20 23:05:28 shane Exp $ /* This example shows how to mark up a server object so that @@ -217,7 +217,7 @@ $server = new SOAP_Server; $server->_auto_translation = true; $MP3DB_Class = new MP3DB_Class(); -$server->addObjectMap($MP3DB_Class,$server->method_namespace); +$server->addObjectMap($MP3DB_Class,'urn:MP3DB'); if (isset($_SERVER['REQUEST_METHOD']) &&

« previous php.pear.cvs (#9998) next »