API Documentation

Soap/Wsdl.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Soap
version
$Id: Wsdl.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Soap_Wsdl

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Soap_Wsdl

category
Zend
package
Zend_Soap
Properties
$_dom
$_wsdl
$_uri
$_schema
$_includedTypes
$_strategy
Methods
__construct
setUri
setComplexTypeStrategy
getComplexTypeStrategy
addMessage
addPortType
addPortOperation
addBinding
addBindingOperation
addSoapBinding
addSoapOperation
addService
addDocumentation
addTypes
addType
getTypes
getSchema
toXML
toDomDocument
dump
getType
addSchemaTypeSection
addComplexType
_parseElement
addElement

Description

Zend_Soap_Wsdl

Properties

$_dom

object $_dom = ''

Details

$_dom
object
DomDocument Instance
visibility
private
default
final
false
static
false

$_includedTypes

array $_includedTypes = 'array'

Types defined on schema

Details

$_includedTypes
array
visibility
private
default
array
final
false
static
false

$_schema

DOMElement $_schema = 'null'

Details

$_schema
DOMElement
visibility
private
default
null
final
false
static
false

$_strategy

 $_strategy = 'null'

Strategy for detection of complex types

Details

visibility
protected
default
null
final
false
static
false

$_uri

string $_uri = ''

Details

$_uri
string
URI where the WSDL will be available
visibility
private
default
final
false
static
false

$_wsdl

object $_wsdl = ''

Details

$_wsdl
object
WSDL Root XML_Tree_Node
visibility
private
default
final
false
static
false

Methods

__construct

__construct( string $name, string $uri, boolean|string|Zend_Soap_Wsdl_Strategy_Interface $strategy = true ) :

Constructor

Arguments
$name
string
Name of the Web Service being Described
$uri
string
URI where the WSDL will be available
$strategy
booleanstringZend_Soap_Wsdl_Strategy_Interface
Details
visibility
public
final
false
static
false

_parseElement

_parseElement( array $element ) : DOMElement

Parse an xsd:element represented as an array into a DOMElement.

Arguments
$element
array
an xsd:element represented as an array
Output
DOMElement
parsed element
Details
visibility
private
final
false
static
false

addBinding

addBinding( string $name,  $portType ) : object

Add a {@link http://www.w3.org/TR/wsdl#_bindings binding} element to WSDL

Arguments
$name
string
Name of the Binding
$portType
Output
object
The new binding's XML_Tree_Node for use with {@link function addBindingOperation} and {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addBindingOperation

addBindingOperation( object $binding,  $name, array $input = false, array $output = false, array $fault = false ) : object

Add an operation to a binding element

Arguments
$binding
object
A binding XML_Tree_Node returned by {@link function addBinding}
$name
$input
array
An array of attributes for the input element, allowed keys are: 'use', 'namespace', 'encodingStyle'. {@link http://www.w3.org/TR/wsdl#_soap:body More Information}
$output
array
An array of attributes for the output element, allowed keys are: 'use', 'namespace', 'encodingStyle'. {@link http://www.w3.org/TR/wsdl#_soap:body More Information}
$fault
array
An array of attributes for the fault element, allowed keys are: 'name', 'use', 'namespace', 'encodingStyle'. {@link http://www.w3.org/TR/wsdl#_soap:body More Information}
Output
object
The new Operation's XML_Tree_Node for use with {@link function addSoapOperation} and {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addComplexType

addComplexType( string $type ) : string

Add a {@link http://www.w3.org/TR/wsdl#_types types} data type definition

Arguments
$type
string
Name of the class to be specified
Output
string
XSD Type for the given PHP type
Details
visibility
public
final
false
static
false

addDocumentation

addDocumentation( object $input_node, string $documentation ) : DOMElement

Add a documentation element to any element in the WSDL.

Note that the WSDL {@link http://www.w3.org/TR/wsdl#_documentation specification} uses 'document', but the WSDL {@link http://schemas.xmlsoap.org/wsdl/ schema} uses 'documentation' instead. The {@link http://www.ws-i.org/Profiles/BasicProfile-1.1-2004-08-24.html#WSDL_documentation_Element WS-I Basic Profile 1.1} recommends using 'documentation'.

Arguments
$input_node
object
An XML_Tree_Node returned by another method to add the documentation to
$documentation
string
Human readable documentation for the node
Output
DOMElement
The documentation element
Details
visibility
public
final
false
static
false

addElement

addElement( array $element ) : string

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:

Arguments
$element
array
an xsd:element represented as an array
Output
string
xsd:element for the given element array
Details
visibility
public
final
false
static
false

addMessage

addMessage( string $name, array $parts ) : object

Add a {@link http://www.w3.org/TR/wsdl#_messages message} element to the WSDL

Arguments
$name
string
Name for the {@link http://www.w3.org/TR/wsdl#_messages message}
$parts
array
An array of {@link http://www.w3.org/TR/wsdl#_message 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')
Output
object
The new message's XML_Tree_Node for use in {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addPortOperation

addPortOperation( object $portType, string $name, string $input = false, string $output = false, string $fault = false ) : object

Add an {@link http://www.w3.org/TR/wsdl#_request-response operation} element to a portType element

Arguments
$portType
object
a portType XML_Tree_Node, from {@link function addPortType}
$name
string
Operation name
$input
string
Input Message
$output
string
Output Message
$fault
string
Fault Message
Output
object
The new operation's XML_Tree_Node for use in {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addPortType

addPortType( string $name ) : object

Add a {@link http://www.w3.org/TR/wsdl#_porttypes portType} element to the WSDL

Arguments
$name
string
portType element's name
Output
object
The new portType's XML_Tree_Node for use in {@link function addPortOperation} and {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addSchemaTypeSection

addSchemaTypeSection( ) : Zend_Soap_Wsdl

This function makes sure a complex types section and schema additions are set.

Details
visibility
public
final
false
static
false

addService

addService( string $name, string $port_name, string $binding, string $location ) : object

Add a {@link http://www.w3.org/TR/wsdl#_services service} element to the WSDL

Arguments
$name
string
Service Name
$port_name
string
Name of the port for the service
$binding
string
Binding for the port
$location
string
SOAP Address for the service
Output
object
The new service's XML_Tree_Node for use with {@link function addDocumentation}
Details
visibility
public
final
false
static
false

addSoapBinding

addSoapBinding( object $binding, string $style = document, string $transport = http://schemas.xmlsoap.org/soap/http ) : boolean

Add a {@link http://www.w3.org/TR/wsdl#_soap:binding SOAP binding} element to a Binding element

Arguments
$binding
object
A binding XML_Tree_Node returned by {@link function addBinding}
$style
string
binding style, possible values are "rpc" (the default) and "document"
$transport
string
Transport method (defaults to HTTP)
Output
boolean
Details
visibility
public
final
false
static
false

addSoapOperation

addSoapOperation(  $binding, string $soap_action ) : boolean

Add a {@link http://www.w3.org/TR/wsdl#_soap:operation SOAP operation} to an operation element

Arguments
$binding
$soap_action
string
SOAP Action
Output
boolean
Details
visibility
public
final
false
static
false

addType

addType( string $type ) : Zend_Soap_Wsdl

Add a complex type name that is part of this WSDL and can be used in signatures.

Arguments
$type
string
Details
visibility
public
final
false
static
false

addTypes

addTypes( object $types ) :

Add WSDL Types element

Arguments
$types
object
A DomDocument|DomNode|DomElement|DomDocumentFragment with all the XML Schema types defined in it
Details
visibility
public
final
false
static
false

dump

dump(  $filename = false ) : boolean

Echo the WSDL as XML

Arguments
$filename
Output
boolean
Details
visibility
public
final
false
static
false

getComplexTypeStrategy

getComplexTypeStrategy( ) : Zend_Soap_Wsdl_Strategy_Interface

Get the current complex type strategy

Details
visibility
public
final
false
static
false

getSchema

getSchema( ) : DOMElement

Return the Schema node of the WSDL

Output
DOMElement
Details
visibility
public
final
false
static
false

getType

getType( string $type ) : string

Returns an XSD Type for the given PHP type

Arguments
$type
string
PHP Type to get the XSD type for
Output
string
Details
visibility
public
final
false
static
false

getTypes

getTypes( ) : array

Return an array of all currently included complex types

Output
array
Details
visibility
public
final
false
static
false

setComplexTypeStrategy

setComplexTypeStrategy( boolean|string|Zend_Soap_Wsdl_Strategy_Interface $strategy ) : Zend_Soap_Wsdl

Set a strategy for complex type detection and handling

Arguments
$strategy
booleanstringZend_Soap_Wsdl_Strategy_Interface
Details
visibility
public
final
false
static
false
todo
Boolean is for backwards compability with extractComplexType object var. Remove it in later versions.

setUri

setUri( string|Zend_Uri_Http $uri ) : Zend_Server_Wsdl

Set a new uri for this WSDL

Arguments
$uri
stringZend_Uri_Http
Output
Zend_Server_Wsdl
Details
visibility
public
final
false
static
false

toDomDocument

toDomDocument( ) : object

Return DOM Document

Output
object
DomDocum ent
Details
visibility
public
final
false
static
false

toXML

toXML( ) : string

Return the WSDL as XML

Output
string
WSDL as XML
Details
visibility
public
final
false
static
false
Documentation was generated by DocBlox.