Zend Framework
1.12
|
Public Member Functions | |
__construct ($name, $uri, $strategy=true) | |
Constructor. | |
setUri ($uri) | |
Set a new uri for this WSDL. | |
setComplexTypeStrategy ($strategy) | |
Set a strategy for complex type detection and handling. | |
getComplexTypeStrategy () | |
Get the current complex type strategy. | |
addMessage ($name, $parts) | |
Add a message element to the WSDL. | |
addPortType ($name) | |
Add a portType element to the WSDL. | |
addPortOperation ($portType, $name, $input=false, $output=false, $fault=false) | |
Add an operation element to a portType element. | |
addBinding ($name, $portType) | |
Add a binding element to WSDL. | |
addBindingOperation ($binding, $name, $input=false, $output=false, $fault=false) | |
Add an operation to a binding element. | |
addSoapBinding ($binding, $style= 'document', $transport= 'http://schemas.xmlsoap.org/soap/http') | |
Add a SOAP binding element to a Binding element. | |
addSoapOperation ($binding, $soap_action) | |
Add a SOAP operation to an operation element. | |
addService ($name, $port_name, $binding, $location) | |
Add a service element to the WSDL. | |
addDocumentation ($input_node, $documentation) | |
Add a documentation element to any element in the WSDL. | |
addTypes ($types) | |
Add WSDL Types element. | |
addType ($type) | |
Add a complex type name that is part of this WSDL and can be used in signatures. | |
getTypes () | |
Return an array of all currently included complex types. | |
getSchema () | |
Return the Schema node of the WSDL. | |
toXML () | |
Return the WSDL as XML. | |
toDomDocument () | |
Return DOM Document. | |
dump ($filename=false) | |
Echo the WSDL as XML. | |
getType ($type) | |
Returns an XSD Type for the given PHP type. | |
addSchemaTypeSection () | |
This function makes sure a complex types section and schema additions are set. | |
addComplexType ($type) | |
Add a types data type definition. | |
addElement ($element) | |
Add an xsd:element represented as an array to the schema. | |
Protected Attributes | |
$_strategy = null | |
Strategy for detection of complex types. | |
__construct | ( | $name, | |
$uri, | |||
$strategy = true |
|||
) |
Constructor.
string | $name | Name of the Web Service being Described |
string | $uri | URI where the WSDL will be available |
boolean | string | Zend_Soap_Wsdl_Strategy_Interface | $strategy |
addBinding | ( | $name, | |
$portType | |||
) |
Add a binding element to WSDL.
string | $name | Name of the Binding |
string | $type | name of the portType to bind |
addBindingOperation | ( | $binding, | |
$name, | |||
$input = false , |
|||
$output = false , |
|||
$fault = false |
|||
) |
Add an operation to a binding element.
object | $binding | A binding XML_Tree_Node returned by addBinding |
array | $input | An array of attributes for the input element, allowed keys are: 'use', 'namespace', 'encodingStyle'. More Information |
array | $output | An array of attributes for the output element, allowed keys are: 'use', 'namespace', 'encodingStyle'. More Information |
array | $fault | An array of attributes for the fault element, allowed keys are: 'name', 'use', 'namespace', 'encodingStyle'. More Information |
Note. Do we really need name attribute to be also set at wsdl:fault node??? W3C standard doesn't mention it (http://www.w3.org/TR/wsdl#_soap:fault) But some real world WSDLs use it, so it may be required for compatibility reasons.
addComplexType | ( | $type | ) |
Add a types data type definition.
string | $type | Name of the class to be specified |
addDocumentation | ( | $input_node, | |
$documentation | |||
) |
Add a documentation element to any element in the WSDL.
Note that the WSDL specification uses 'document', but the WSDL schema uses 'documentation' instead. The WS-I Basic Profile 1.1 recommends using 'documentation'.
object | $input_node | An XML_Tree_Node returned by another method to add the documentation to |
string | $documentation | Human readable documentation for the node |
addElement | ( | $element | ) |
Add an xsd:element represented as an array to the schema.
Array keys represent attribute names and values their respective value. The 'sequence', 'all' and 'choice' keys must have an array of elements as their value, to add them to a nested complexType.
Example: array( 'name' => 'MyElement', 'sequence' => array( array('name' => 'myString', 'type' => 'string'), array('name' => 'myInteger', 'type' => 'int') ) ); Resulting XML: <xsd:element name="MyElement"><xsd:complexType><xsd:sequence> <xsd:element name="myString" type="string"/> <xsd:element name="myInteger" type="int"/> </xsd:sequence></xsd:complexType></xsd:element>
array | $element | an xsd:element represented as an array |
addMessage | ( | $name, | |
$parts | |||
) |
Add a message element to the WSDL.
string | $name | Name for the message |
array | $parts | An array of parts The array is constructed like: 'name of part' => 'part xml schema data type' or 'name of part' => array('type' => 'part xml schema type') or 'name of part' => array('element' => 'part xml element name') |
addPortOperation | ( | $portType, | |
$name, | |||
$input = false , |
|||
$output = false , |
|||
$fault = false |
|||
) |
Add an operation element to a portType element.
object | $portType | a portType XML_Tree_Node, from addPortType |
string | $name | Operation name |
string | $input | Input Message |
string | $output | Output Message |
string | $fault | Fault Message |
addPortType | ( | $name | ) |
Add a portType element to the WSDL.
string | $name | portType element's name |
addSchemaTypeSection | ( | ) |
This function makes sure a complex types section and schema additions are set.
addService | ( | $name, | |
$port_name, | |||
$binding, | |||
$location | |||
) |
Add a service element to the WSDL.
string | $name | Service Name |
string | $port_name | Name of the port for the service |
string | $binding | Binding for the port |
string | $location | SOAP Address for the service |
addSoapBinding | ( | $binding, | |
$style = 'document' , |
|||
$transport = 'http://schemas.xmlsoap.org/soap/http' |
|||
) |
Add a SOAP binding element to a Binding element.
object | $binding | A binding XML_Tree_Node returned by addBinding |
string | $style | binding style, possible values are "rpc" (the default) and "document" |
string | $transport | Transport method (defaults to HTTP) |
addSoapOperation | ( | $binding, | |
$soap_action | |||
) |
Add a SOAP operation to an operation element.
object | $operation | An operation XML_Tree_Node returned by addBindingOperation |
string | $soap_action | SOAP Action |
addType | ( | $type | ) |
Add a complex type name that is part of this WSDL and can be used in signatures.
string | $type |
addTypes | ( | $types | ) |
Add WSDL Types element.
object | $types | A DomDocument|DomNode|DomElement|DomDocumentFragment with all the XML Schema types defined in it |
dump | ( | $filename = false | ) |
Echo the WSDL as XML.
getComplexTypeStrategy | ( | ) |
Get the current complex type strategy.
getSchema | ( | ) |
Return the Schema node of the WSDL.
getType | ( | $type | ) |
Returns an XSD Type for the given PHP type.
string | $type | PHP Type to get the XSD type for |
getTypes | ( | ) |
Return an array of all currently included complex types.
setComplexTypeStrategy | ( | $strategy | ) |
Set a strategy for complex type detection and handling.
boolean | string | Zend_Soap_Wsdl_Strategy_Interface | $strategy |
setUri | ( | $uri | ) |
toDomDocument | ( | ) |
Return DOM Document.
toXML | ( | ) |
Return the WSDL as XML.
|
protected |
Strategy for detection of complex types.