Become Zend Certified

Prepare for the ZCE exam using our quizzes (web or iPad/iPhone). More info...

When you're ready get 7.5% off your exam voucher using voucher CJQNOV23 at the Zend Store

Autodiscovering Datatypes

Input/output datatypes are converted into network service types using the following mapping:

  • PHP strings <-> xsd:string.

  • PHP integers <-> xsd:int.

  • PHP floats and doubles <-> xsd:float.

  • PHP booleans <-> xsd:boolean.

  • PHP arrays <-> soap-enc:Array.

  • PHP object <-> xsd:struct.

  • PHP class <-> based on complex type strategy (See: this section) [29].

  • type[] or object[] (ie. int[]) <-> based on complex type strategy

  • PHP void <-> empty type.

  • If type is not matched to any of these types by some reason, then xsd:anyType is used.

Where xsd: is "" namespace, soap-enc: is a "" namespace, tns: is a "target namespace" for a service.

[29] Zend_Soap_AutoDiscover will be created with the Zend_Soap_Wsdl_Strategy_DefaultComplexType class as detection algorithm for complex types. The first parameter of the AutoDiscover constructor takes any complex type strategy implementing Zend_Soap_Wsdl_Strategy_Interface or a string with the name of the class. For backwards compatibility with $extractComplexType boolean variables are parsed exactly like in Zend_Soap_Wsdl. See the Zend_Soap_Wsdl manual on adding complex types for more information.

Zend Framework