upnptools.h
Go to the documentation of this file.
/*******************************************************************************
*
* Copyright (c) 2000-2003 Intel Corporation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* * Neither name of Intel Corporation nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
******************************************************************************/
#ifndef UPNP_TOOLS_H
#define UPNP_TOOLS_H
#include "ixml.h" /* for IXML_Document */
#include "upnpconfig.h" /* for UPNP_HAVE_TOOLS */
/* Function declarations only if tools compiled into the library */
#if UPNP_HAVE_TOOLS
#ifdef __cplusplus
extern "C" {
#endif
UPNP_EXPORT_SPEC void UpnpSetMaxJobsTotal(int mjt);
UPNP_EXPORT_SPEC const char *UpnpGetErrorMessage(
int errorcode);
UPNP_EXPORT_SPEC int UpnpResolveURL(
const char *BaseURL,
const char *RelURL,
char *AbsURL);
UPNP_EXPORT_SPEC int UpnpResolveURL2(
const char *BaseURL,
const char *RelURL,
char **AbsURL);
UPNP_EXPORT_SPEC IXML_Document *UpnpMakeAction(
const char *ActionName,
const char *ServType,
int NumArg,
const char *Arg,
...);
UPNP_EXPORT_SPEC IXML_Document *UpnpMakeActionResponse(
const char *ActionName,
const char *ServType,
int NumArg,
const char *Arg,
...);
UPNP_EXPORT_SPEC int UpnpAddToAction(
IXML_Document **ActionDoc,
const char *ActionName,
const char *ServType,
const char *ArgName,
const char *ArgVal);
UPNP_EXPORT_SPEC int UpnpAddToActionResponse(
IXML_Document **ActionResponse,
const char *ActionName,
const char *ServType,
const char *ArgName,
const char *ArgVal);
UPNP_EXPORT_SPEC IXML_Document *UpnpCreatePropertySet(
int NumArg,
const char *Arg,
...);
UPNP_EXPORT_SPEC int UpnpAddToPropertySet(
IXML_Document **PropSet,
const char *ArgName,
const char *ArgVal);
#ifdef __cplusplus
}
#endif
#endif /* UPNP_HAVE_TOOLS */
#endif /* UPNP_TOOLS_H */
UPNP_EXPORT_SPEC
#define UPNP_EXPORT_SPEC
Export functions on WIN32 DLLs.
Definition UpnpGlobal.h:105
UpnpGetErrorMessage
UPNP_EXPORT_SPEC const char * UpnpGetErrorMessage(int errorcode)
Converts an SDK error code into a string error message suitable for display. The memory returned from...
Definition upnptools.c:117
UpnpAddToActionResponse
UPNP_EXPORT_SPEC int UpnpAddToActionResponse(IXML_Document **ActionResponse, const char *ActionName, const char *ServType, const char *ArgName, const char *ArgVal)
Creates an action response packet based on its output parameters (status variable name and value pair...
Definition upnptools.c:393
UpnpResolveURL
UPNP_EXPORT_SPEC int UpnpResolveURL(const char *BaseURL, const char *RelURL, char *AbsURL)
Combines a base URL and a relative URL into a single absolute URL.
Definition upnptools.c:137
UpnpCreatePropertySet
UPNP_EXPORT_SPEC IXML_Document * UpnpCreatePropertySet(int NumArg, const char *Arg,...)
Creates a property set message packet.
Definition upnptools.c:403
UpnpMakeAction
UPNP_EXPORT_SPEC IXML_Document * UpnpMakeAction(const char *ActionName, const char *ServType, int NumArg, const char *Arg,...)
Creates an action request packet based on its input parameters (status variable name and value pair).
Definition upnptools.c:351
UpnpResolveURL2
UPNP_EXPORT_SPEC int UpnpResolveURL2(const char *BaseURL, const char *RelURL, char **AbsURL)
Combines a base URL and a relative URL into a single absolute URL.
Definition upnptools.c:157
UpnpAddToAction
UPNP_EXPORT_SPEC int UpnpAddToAction(IXML_Document **ActionDoc, const char *ActionName, const char *ServType, const char *ArgName, const char *ArgVal)
Adds the argument in the action request.
Definition upnptools.c:383
UpnpSetMaxJobsTotal
UPNP_EXPORT_SPEC void UpnpSetMaxJobsTotal(int mjt)
Sets the maximum number of jobs in the internal thread pool. This option is intended for server appli...
Definition upnptools.c:130
UpnpMakeActionResponse
UPNP_EXPORT_SPEC IXML_Document * UpnpMakeActionResponse(const char *ActionName, const char *ServType, int NumArg, const char *Arg,...)
Ceates an action response packet based on its output parameters (status variable name and value pair)...
Definition upnptools.c:367
UpnpAddToPropertySet
UPNP_EXPORT_SPEC int UpnpAddToPropertySet(IXML_Document **PropSet, const char *ArgName, const char *ArgVal)
Can be used when an application needs to transfer the status of many variables at once.
Definition upnptools.c:450
ixml.h
_IXML_Document
Data structure representing the DOM Document.
Definition ixml.h:160