UPnPsdk 0.1
Universal Plug and Play +, Software Development Kit
 
Loading...
Searching...
No Matches
soap_ctrlpt.hpp File Reference

SOAP declarations for Control Points using SOAP. More...

#include <ixml/ixml.hpp>
+ Include dependency graph for soap_ctrlpt.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int SoapSendAction (char *action_url, char *service_type, IXML_Document *action_node, IXML_Document **response_node)
 This function is called by UPnP API to send the SOAP action request.
 
int SoapSendActionEx (char *action_url, char *service_type, IXML_Document *header, IXML_Document *action_node, IXML_Document **response_node)
 This extended function is called by UPnP API to send the SOAP action request.
 
int SoapGetServiceVarStatus (char *action_url, DOMString var_name, DOMString *var_value)
 This function creates a status variable query message send it to the specified URL. It also collect the response.
 

Detailed Description

SOAP declarations for Control Points using SOAP.

Definition in file soap_ctrlpt.hpp.

Function Documentation

◆ SoapSendAction()

int SoapSendAction ( char *  action_url,
char *  service_type,
IXML_Document action_node,
IXML_Document **  response_node 
)

This function is called by UPnP API to send the SOAP action request.

It waits till it gets the response from the device pass the response to the API layer.

Returns
On success: UPNP_E_SUCCESS
On error:
  • UPNP_E_OUTOF_MEMORY
  • UPNP_E_INVALID_ACTION
  • UPNP_E_INVALID_URL
  • UPNP_E_SOCKET_ERROR
  • UPNP_E_SOCKET_CONNECT
  • UPNP_E_FILE_READ_ERROR
  • UPNP_E_TIMEDOUT
  • UPNP_E_SOCKET_WRITE
  • UPNP_E_BAD_HTTPMSG
  • may have additional error codes
Parameters
[in]action_urldevice contrl URL.
[in]service_typedevice service type.
[in]action_nodeSOAP action node.
[out]response_nodeSOAP response node.

Definition at line 490 of file soap_ctrlpt.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SoapSendActionEx()

int SoapSendActionEx ( char *  action_url,
char *  service_type,
IXML_Document header,
IXML_Document action_node,
IXML_Document **  response_node 
)

This extended function is called by UPnP API to send the SOAP action request.

The function waits till it gets the response from the device pass the response to the API layer. This action is similar to the SoapSendAction() with only difference that it allows users to pass the SOAP header along the SOAP body (soap action request).

Returns
On success: UPNP_E_SUCCESS
On error:
  • UPNP_E_BAD_RESPONSE
  • UPNP_E_OUTOF_MEMORY
  • UPNP_E_INVALID_ACTION
  • UPNP_E_INVALID_URL
  • UPNP_E_SOCKET_ERROR
  • UPNP_E_SOCKET_CONNECT
  • UPNP_E_FILE_READ_ERROR
  • UPNP_E_TIMEDOUT
  • UPNP_E_SOCKET_WRITE
  • UPNP_E_BAD_HTTPMSG
  • SOAP_ACTION_RESP
  • SOAP_VAR_RESP
  • SOAP_VAR_RESP_ERROR
  • SOAP_ACTION_RESP_ERROR
  • HTTP error codes >400
Parameters
[in]action_urldevice contrl URL.
[in]service_typedevice service type.
[in]headerSoap header.
[in]action_nodeSOAP action node (SOAP body).
[out]response_nodeSOAP response node.

Definition at line 605 of file soap_ctrlpt.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SoapGetServiceVarStatus()

int SoapGetServiceVarStatus ( char *  action_url,
DOMString  var_name,
DOMString var_value 
)

This function creates a status variable query message send it to the specified URL. It also collect the response.

Returns
On success: UPNP_E_SUCCESS
On error:
  • UPNP_E_SOCKET_ERROR
  • UPNP_E_SOCKET_CONNECT
  • UPNP_E_OUTOF_MEMORY
  • UPNP_E_FILE_READ_ERROR
  • UPNP_E_TIMEDOUT
  • UPNP_E_SOCKET_WRITE
  • UPNP_E_BAD_HTTPMSG
  • UPNP_E_BAD_RESPONSE
  • SOAP_ACTION_RESP
  • SOAP_VAR_RESP
  • SOAP_VAR_RESP_ERROR
  • SOAP_ACTION_RESP_ERROR
  • HTTP error codes >400
Todo:
Returned error message IDs are ambiguous. Fix it.
Todo:
Verify the bug in the source code of this function with a unit test.
Parameters
[in]action_urlAddress to send this variable query message.
[in]var_nameName of the variable.
[out]var_valueOutput value.

Definition at line 748 of file soap_ctrlpt.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function: