Updated definition of ComplexType and use classmap option of SoapServer

Please to refer to the documentation for the changes:
http://besim.pl/SoapBundle/tutorial/complex_type.html
This commit is contained in:
Francis Besset
2011-08-24 23:36:49 +02:00
parent 51a36dfb87
commit c154463b33
12 changed files with 117 additions and 291 deletions

View File

@ -11,6 +11,7 @@
namespace BeSimple\SoapBundle\Soap;
use BeSimple\SoapBundle\Converter\ConverterRepository;
use Zend\Soap\Wsdl;
/**
* @author Christian Kerl <christian-kerl@web.de>
@ -25,7 +26,7 @@ class SoapServerFactory
public function __construct($wsdlFile, array $classmap, ConverterRepository $converters, $debug = false)
{
$this->wsdlFile = $wsdlFile;
$this->classmap = $classmap;
$this->classmap = $this->fixSoapServerClassmap($classmap);
$this->converters = $converters;
$this->debug = $debug;
}
@ -62,4 +63,15 @@ class SoapServerFactory
return $typemap;
}
private function fixSoapServerClassmap($classmap)
{
$classmapFixed = array();
foreach ($classmap as $class => $definition) {
$classmapFixed[Wsdl::translateType($class)] = $class;
}
return $classmapFixed;
}
}