WSDL::WSOperation Class Reference

web service operation class More...

Inheritance diagram for WSDL::WSOperation:
[legend]

## Public Member Functions

hash | serializeRequest (any h, *hash header, *string enc, *hash nsh, *int xml_opts)
| serializes a request to an XML string for the operation More...
hash | serializeResponse (any h, *hash header, *string enc, *hash nsh, *bool soap12, *int xml_opts)
| serializes a SOAP response to an XML string for the operation More...
any | deserializeRequest (hash o)
| parses a hash representing a parsed XML request (parsed with parseXMLAsData()) for the operation and returns the corresponding Qore data structure More...
any | deserializeResponse (hash o)
| parses a hash representing a parsed XML response (parsed with parse_xml()) for the operation and returns the corresponding Qore data structure More...
bool | isSoap12 ()
| returns True if the operation is a SOAP 1.2 operation More...
string | getTargetNS ()
| returns the target namespace for the operation More...

## Additional Inherited Members

Public Attributes inherited from WSDL::XsdNamedData
*string | ns
| input namespace prefix (if any given)

## Detailed Description

web service operation class

## Member Function Documentation

any WSDL::WSOperation::deserializeRequest | ( | hash | o | ) |

parses a hash representing a parsed XML request (parsed with parseXMLAsData()) for the operation and returns the corresponding Qore data structure

Parameters

  o | the parsed XML request (parsed with parseXMLAsData()) for the operation

Returns
  the Qore data structure corresponding to the request data

any WSDL::WSOperation::deserializeResponse | ( | hash | o | ) |

parses a hash representing a parsed XML response (parsed with parse_xml()) for the operation and returns the corresponding Qore data structure

Parameters

  o | the parsed XML response (parsed with parse_xml()) for the operation

Returns
  the Qore data structure corresponding to the response data

string WSDL::WSOperation::getTargetNS | ( |  | ) |

returns the target namespace for the operation

Returns
  the target namespace for the operation

bool WSDL::WSOperation::isSoap12 | ( |  | ) |

returns True if the operation is a SOAP 1.2 operation

Returns
  True if the operation is a SOAP 1.2 operation

hash WSDL::WSOperation::serializeRequest | ( | any | h,
|  | *hash | header,
|  | *string | enc,
|  | *hash | nsh,
|  | *int | xml_opts
| ) |  |

serializes a request to an XML string for the operation

Parameters

  h | the request to serialize
  header | optional soap header info to serialize if required (ex: authorization info)
  enc | the optional encoding to use; if this argument is not present, then the default encoding will be used
  nsh | an optional namespace hash for the output message
  xml_opts | optional XML generation options

Returns
  a hash with keys:
  - `body:` XML string in the SOAP request format
  - `hdr:` hash of HTTP headers

hash WSDL::WSOperation::serializeResponse | ( | any | h,
|  | *hash | header,
|  | *string | enc,
|  | *hash | nsh,
|  | *bool | soap12,
|  | *int | xml_opts
| ) |  |

serializes a SOAP response to an XML string for the operation

Parameters

  h | the response to serialize
  header | SOAP header hash
  enc | the optional encoding to use; if this argument is not present, then the default encoding will be used
  nsh | namespace hash
  soap12 | set to True if the response should use SOAP 1.2 encoding
  xml_opts | optional XML generation options

Returns
  a hash with keys:
  - `body:` XML string in the SOAP request format
  - `hdr:` hash of HTTP headers