|  | Home | Documentation | stdsoap2.h File Reference updated by Robert van Engelen |

stdsoap2.h File Reference

This file defines the common macros, types and functions of the gSOAP API grouped by modules. More...

## Classes

struct | soap
| Context with the engine state. More...
struct | soap_cookie
| Cookie structure. More...
struct | Namespace
| Structure of each row in a namespace table. More...
struct | SOAP_ENV__Header
| SOAP Header structure. More...
struct | SOAP_ENV__Fault
| SOAP Fault structure. More...
struct | SOAP_ENV__Code
| SOAP Fault Code structure. More...
struct | SOAP_ENV__Detail
| SOAP Fault Detail structure. More...
struct | SOAP_ENV__Reason
| SOAP Fault Reason structure generated by soapcpp2. More...
struct | xsd__base64Binary
| XSD base64Binary structure with attachment data. More...
struct | _xop__Include
| XOP include structure with attachment data. More...
struct | xsd__hexBinary
| XSD hexBinary structure with attachment data. More...
struct | soap_dime
| Stores a linked list of DIME attachments received. More...
struct | soap_mime
| Stores a linked list of MIME attachments received. More...
struct | soap_multipart
| DIME/MIME/MTOM attachment data received by the engine. More...

## Macros

#define | DEBUG
| User-definable macro to enable debugging and logging.
#define | SOAP_DEBUG
| User-definable macro, enables #DEBUG mode for runtime debug logs, but without enabling #SOAP_MEM_DEBUG memory debugging.
#define | DEBUG_STAMP
| User-definable macro to enable debugging and logging with time stamps.
#define | SOAP_MEM_DEBUG
| User-definable macro to enable memory debugging without #SOAP_DEBUG logging.
#define | SOAPDEFS_H
| When this macro is defined at compile time (undefined by default) then the header file specified by this macro is included in the build via stdsoap2.h.
#define | WITH_SOAPDEFS_H
| When this macro is defined at compile time (undefined by default), a user-supplied file named soapdefs.h is included in the build, i.e. soapdefs.h can be used to configure the build by defining compile-time macros and flags.
#define | WITH_COMPAT
| When this macro is defined at compile time (undefined by default), removes dependency on C++ std::string and std::iostream libraries.
#define | WITH_LEAN
| When this macro is defined at compile time (undefined by default), memory footprint is significantly reduced by removing non-essential features from the engine and from the generated code.
#define | WITH_LEANER
| When this macro is defined at compile time (undefined by default), memory footprint is further reduced from #WITH_LEAN by removing non-essential features from the engine and from the generated code.
#define | WITH_FAST
| When this macro is defined at compile time uses faster memory allocation at a cost of larger memory blocks allocated (defined by default except with #WITH_LEAN and #WITH_LEANER).
#define | WITH_COOKIES
| When this macro is defined at compile time (undefined by default), HTTP cookie support is enabled in the engine.
#define | WITH_INSECURE_COOKIES
| When this macro is defined at compile time (undefined by default), HTTP cookie support is enabled (as #WITH_COOKIES) but allows cookies with their Secure flag set to be sent over insecure channels.
#define | WITH_IPV6
| When this macro is defined at compile time (undefined by default), IPv6 support is enabled and both IPv4 and IPv6 connections are supported by the engine.
#define | WITH_IPV6_V6ONLY
| When this macro is defined at compile time (undefined by default), IPv6-only is enabled for port binding at the server side by the engine to ensure that a socket will only use IPv6 without mapping IPv4 to IPv6.
#define | WITH_OPENSSL
| When this macro is defined at compile time (undefined by default), enables activation and linkage with OpenSSL for HTTPS and WS-Security (this macro should also be defined when using plugins that rely on OpenSSL).
#define | WITH_GNUTLS
| When this macro is defined at compile time (undefined by default), enables activation and linkage the GNUTLS library to enable HTTPS in the engine.
#define | WITH_WOLFSSL
| When this macro is defined at compile time (undefined by default), enables activation and linkage of the WolfSSL library to enable HTTPS in the engine.
#define | WITH_GZIP
| When this macro is defined at compile time (undefined by default), enables linkage with the zlib library for HTTP message compression (using compress and gzip methods) when the #SOAP_ENC_ZLIB mode flag is enabled at runtime.
#define | WITH_ZLIB
| When this macro is defined at compile time (undefined by default), enables linking the zlib library for HTTP message compression when the #SOAP_ENC_ZLIB mode flag is enabled at runtime.
#define | WITH_NTLM
| When this macro is defined at compile time (undefined by default), enables linkage with the ntlm library for HTTP NTLM authentication.
#define | WITH_C_LOCALE
| When this macro is defined at compile time (defined by default for most platforms), the C locale is enabled in the engine, opposite of #WITH_NO_C_LOCALE.
#define | WITH_NO_C_LOCALE
| When this macro is defined at compile time (undefined by default), the use of the C locale is disabled in the engine, the opposite of #WITH_C_LOCALE.
#define | WITH_INCLUDE_XLOCALE_H
| When this macro is defined at compile time (defined by default for most platforms), include xlocale.h to define locale_t and the _l locale-specific functions.
#define | WITH_DOM
| When this macro is defined at compile time (undefined by default), enables WS-Security signature verification and XML re-canonicalization, i.e. this macro must be defined when using the gSOAP WSSE plugin for WS-Security.
#define | WITH_REPLACE_ILLEGAL_UTF8
| When this macro is defined at compile time (undefined by default), replaces UTF-8 content that is outside the Unicode range with the value of #SOAP_UNKNOWN_UNICODE_CHAR (Unicode FFFD) to indicate illegal UTF-8, set #SOAP_UNKNOWN_UNICODE_CHAR to another integer code if desired (the value is 0xFFFD by default).
#define | WITH_FASTCGI
| When this macro is defined at compile time (undefined by default), enables and configures the engine and generated code to use FastCGI at the server side.
#define | WITH_NOIO
| When this macro is defined at compile time (undefined by default), removes all IO and socket library calls to replace these with user-supplied callback functions, see the IO callbacks in the user guide.
#define | WITH_NOIDREF
| When this macro is defined at compile time (undefined by default), permanently disables XML ID (id attribute) and REF (href or ref attribute) processing rules associated with SOAP 1.1 and SOAP 1.2 "multi-reference" data to serialize object graphs, this is a more aggressive optimization option than the runtime #SOAP_XML_TREE flag.
#define | WITH_NOHTTP
| When this macro is defined at compile time (undefined by default), permanently removes the HTTP stack to reduce code size.
#define | WITH_NOZONE
| When this macro is defined at compile time (undefined by default), removes and ignores the timezone in xsd:dateTime values.
#define | WITH_NOEMPTYNAMESPACES
| When this macro is defined at compile time, default empty namespaces are not required to parse XML and are disabled from XML messages when the #SOAP_XML_DEFAULTNS mode flag is used.
#define | WITH_NOEMPTYSTRUCT
#define | WITH_NOGLOBAL
| When this macro is defined at compile time (undefined by default), omits SOAP Header and Fault serialization code, this flag prevents duplicate definitions in the source code generated by soapcpp2.
#define | WITH_NONAMESPACES
| When this macro is defined at compile time (undefined by default), removes dependence on the global namespaces table, rather users must set the XML namespaces explicitly by calling soap_set_namespaces.
#define | WITH_CDATA
| When this macro is defined at compile time (undefined by default), retains the parsed CDATA sections in literal XML strings.
#define | WITH_PURE_VIRTUAL
| When this macro is defined at compile time (undefined by default), makes C++ service class operation methods and the copy method pure virtual by defining #SOAP_PURE_VIRTUAL = 0.
#define | WITH_DEFAULT_VIRTUAL
| When this macro is defined at compile time (undefined by default), enables C++ base service classes with default virtual methods returning fault #SOAP_NO_METHOD.
#define | WITH_CASEINSENSITIVETAGS
| When this macro is defined at compile time (undefined by default), enables case insensitive XML tag name parsing and validation.
#define | WITH_SOCKET_CLOSE_ON_EXIT
| When this macro is defined at compile time (undefined by default), prevents a server port from staying in listening mode after exit by internally setting fcntl(sock, F_SETFD, FD_CLOEXEC).
#define | WITH_TCPFIN
| When this macro is defined at compile time (undefined by default), the engine transmits TCP FIN using shutdown(sock, SHUT_WR) after all sends are completed and just before the socket closes.
#define | WITH_SSL_FULL_SHUTDOWN
| When this macro is defined at compile time (undefined by default), the engine calls SSL_shutdown(ssl) twice, the second after close_notify (with a 5 second timeout), before closing the socket (WITH_LEAN n/a: calls SSL_shutdown(ssl) a second time without any timeout).
#define | WITH_SELF_PIPE
| When this macro is defined at compile time (undefined by default), the engine is configured to enable ::soap_close_connection using a "self-pipe".
#define | WITH_CRTOLF
| When this macro is defined at compile time (undefined by default), the engine is configured to replace CRLF (carriage return #xD followed by line feed #xA) by LF and replace single CR by LF.
#define | WITH_POSIX_STRERROR_R
| When this macro is defined at compile time (undefined by default), the XSI-compliant POSIX version of strerror_r is expected instead of the GNU-specific strerror_r.
#define | SOAP_NOTHROW (std::nothrow)
| Macro expands to (std::nothrow) to prevent the deserializer's memory allocator from throwing an exception but return #SOAP_EOM instead, this macro is empty when #WITH_COMPAT is enabled or when #WITH_LEAN or #WITH_LEANER are enabled which means that exceptions may be thrown.
#define | SOAP_BUFLEN (65536)
| User-definable size of the input and output message buffer soap::buf (the value is 65536 by default).
#define | SOAP_HDRLEN (8192)
| User-definable maximum length of HTTP headers (the value is 8192 by default).
#define | SOAP_TAGLEN (1024)
| User-definable maximum length of XML tags and URLs (the value is 1024 by default).
#define | SOAP_TMPLEN (1024)
| User-definable maximum length of temporary string values stored in soap::msgbuf and soap::tmpbuf, e.g. to hold short strings and brief error messages (1024 by default, must not be less than 1024).
#define | SOAP_MAXALLOCSIZE (0)
| User-definable maximum size of a block of memory that malloc can allocate or 0 for no limit (the value is 0 by default).
#define | SOAP_MAXARRAYSIZE (100000)
| User-definable macro to protect excessive SOAP array allocation requests by defining a maximum allocation threshold.
#define | SOAP_MAXDIMESIZE (8*1048576)
| User-definable maximum length of DIME attachments received (the value is 8 MB by default).
#define | SOAP_MAXEINTR (10)
| User-definable maximum number of EINTR interrupts to ignore while polling a socket for pending activity, each EINTR ignored may increase the I/O blocking time by at most one second (the value is 10 by default).
#define | SOAP_MAXINFLATESIZE (1*1048576)
| Trusted inflated content size (1 MB by default), larger content is subject to the #SOAP_MINDEFLATERATIO constraint, i.e. if #SOAP_MINDEFLATERATIO is 1.0, #SOAP_MAXINFLATESIZE is always the max size of uncompressed content.
#define | SOAP_MAXKEEPALIVE (100)
| User-definable maximum iterations in the server-side soap_serve loop (or the C++ service class serve method) on HTTP keep-alive connections, assigned to soap::max_keep_alive which can be altered at runtime (the value is 100 by default).
#define | SOAP_MAXLENGTH (0)
| User-definable maximum string content length for strings not already constrained by XML schema validation constraints, zero or negative means unlimited string lengths are allowed (the value is 0 by default).
#define | SOAP_MAXLEVEL (10000)
| User-definable maximum XML nesting depth level permitted by the XML parser, must be greater than zero (the value is 10000 by default).
#define | SOAP_MAXOCCURS (100000)
| User-definable maximum number of array or container elements for containers that are not already constrained by XML schema validation constraints, must be greater than zero (the value is 100000 by default).
#define | SOAP_MAXHTTPCHUNK (2147483647)
| User-definable maximum HTTP chunk size receivable (the value is 2147483647 by default), also HTTP chunk sizes cannot exceed soap::recv_maxlength.
#define | SOAP_MINDEFLATERATIO (1.0/1032.0)

Trusted deflation ratio after #SOAP_MAXINFLATESIZE is reached, trust when compressed / deflated > #SOAP_MINDEFLATERATIO (default is 0.00096899224806 or 1032:1, which is according to the zlib site: "The limit (1032:1) comes from the fact that one length/distance pair can represent at most 258 output bytes. A length requires at least one bit and a distance requires at least one bit, so two bits in can give 258 bytes out, or eight bits in give 1032 bytes out. A dynamic block has no length restriction, so you could get arbitrarily close to the limit of 1032:1.".

#define | SOAP_PURE_VIRTUAL = 0
| Macro is set to #SOAP_PURE_VIRTUAL = 0 at compile time when macro #WITH_PURE_VIRTUAL is defined.
#define | SOAP_SSL_RSA_BITS (2048)
| User-definable length of RSA keys used for https connections (the value is 2048 by default), ignored with OpenSSL v3.
#define | SOAP_UNKNOWN_CHAR (0x7F)
| User-definable 8 bit integer that represents a character that could not be converted to an ASCII char, i.e. when converting an XML Unicode character (typically UTF-8), this is applicable when the runtime flag #SOAP_C_UTFSTRING is not used (the value is 0x7F by default).
#define | SOAP_UNKNOWN_UNICODE_CHAR (0xFFFD)
| A user-definable integer Unicode value representing a character that replaces an invalid Unicode code point, i.e. when converting an XML invalid Unicode character from UTF-8 (the value is 0xFFFD by default).
#define | SOAP_LONG_FORMAT "%lld"
| User-definable macro that represents the #LONG64 printf %-format.
#define | SOAP_ULONG_FORMAT "%llu"
| User-definable macro that represents the #ULONG64 printf %-format.
#define | SOAP_SOCKET int
| Macro that defines a portable socket type, usually int, but the type may depend on the platform being used.
#define | SOAP_INVALID_SOCKET (-1)
| Macro that defines a portable invalid socket value (usually -1, but the value depends on the OS).
#define | SOAP_SOCKLEN_T size_t
| Macro that defines a portable socklen_t type (usually size_t, but type depends on the OS).
#define | soap_valid_socket(sock)
| Function macro to check if a socket is valid, i.e. not equal to #SOAP_INVALID_SOCKET.
#define | LONG64 int64_t
| User-definable macro that represents a portable signed 64 bit integer type.
#define | ULONG64 uint64_t
| User-definable macro that represents a portable unsigned 64 bit integer type.
#define | FLT_NAN
| User-definable macro that represents a portable single floating point NaN value (defined by default to a platform-specific NaN value).
#define | FLT_PINFTY
| User-definable macro that represents a portable single floating point positive infinite value (defined by default to a platform-specific value).
#define | FLT_NINFTY
| User-definable macro that represents a portable single floating point negative infinite value (defined by default to a platform-specific value).
#define | DBL_NAN
| User-definable macro that represents a portable double floating point NaN value (defined by default to a platform-specific NaN value).
#define | DBL_PINFTY
| User-definable macro that represents a portable double floating point positive infinite value (defined by default to a platform-specific value).
#define | DBL_NINFTY
| User-definable macro that represents a portable double floating point negative infinite value (defined by default to a platform-specific value).
#define | soap_isnan(x)
| Macro that returns true if the floating point value is NaN.
#define | soap_isinf(x)
| Macro that returns true if the floating point value is infinity.
#define | SOAP_MALLOC(soap, size)
| User-definable macro to override malloc() for context-managed heap allocation (excluding C++ class instances, see #SOAP_NEW).
#define | SOAP_FREE(soap, ptr)
| User-definable macro to override free() for context-managed heap allocation (excluding C++ class instances, see #SOAP_DELETE).
#define | SOAP_MALLOC_UNMANAGED(soap, size)
| User-definable macro to override malloc() for unmanaged heap allocation.
#define | SOAP_FREE_UNMANAGED(soap, ptr)
| User-definable macro to override free() for unmanaged heap allocation.
#define | SOAP_NEW(soap, type)
| User-definable macro to override C++ new.
#define | SOAP_NEW_ARRAY(soap, type, n)
| User-definable macro to override C++ new for arrays.
#define | SOAP_PLACEMENT_NEW(soap, buf, type)
| User-definable macro to override C++ placement new.
#define | SOAP_DELETE(soap, obj, type)
| User-definable macro to override C++ delete.
#define | SOAP_DELETE_ARRAY(soap, obj, type)
| User-definable macro to override C++ delete for arrays.
#define | SOAP_NEW_UNMANAGED(soap)
| User-definable macro to override C++ new for unmanaged allocation of the soap context.
#define | SOAP_DELETE_UNMANAGED(soap)
| User-definable macro to override C++ delete for unmanaged deallocation of the soap context.
#define | SOAP_STD_EXPORTS
| User-definable macro to enable Windows DLL builds.
#define | SOAP_FMAC1
| User-definable macro to annotate global functions.
#define | SOAP_FMAC2
| User-definable macro to annotate global functions.
#define | SOAP_FMAC3
| User-definable macro to annotate global serialization functions generated by soapcpp2.
#define | SOAP_FMAC4
| User-definable macro to annotate global serialization functions generated by soapcpp2.
#define | SOAP_FMAC5
| User-definable macro to annotate global service functions generated by soapcpp2.
#define | SOAP_FMAC6
| User-definable macro to annotate global service functions generated by soapcpp2.
#define | SOAP_CMAC
| User-definable macro to annotate class definitions.
#define | SOAP_NMAC
| User-definable macro to annotate namespace table definitions.
#define | SOAP_IO 0x00000003
| soap_mode IO flags mask to check for #SOAP_IO_FLUSH, #SOAP_IO_BUFFER, #SOAP_IO_STORE, #SOAP_IO_CHUNK (for internal use only)
#define | SOAP_IO_FLUSH 0x00000000
| soap_mode IO output flag value to flush the message sent immediately without buffering (the default mode), do not combine this flag with #SOAP_IO_BUFFER, #SOAP_IO_STORE, #SOAP_IO_CHUNK
#define | SOAP_IO_BUFFER 0x00000001
| soap_mode IO output flag value to buffer the message sent in packets of size #SOAP_BUFLEN, do not combine this flag with #SOAP_IO_FLUSH, #SOAP_IO_STORE, #SOAP_IO_CHUNK
#define | SOAP_IO_STORE 0x00000002
| soap_mode IO output flag value to store messages temporarily before transmission, e.g. to determine message length for transmission over HTTP instead of chunking or two-phase message sends, do not combine this flag with #SOAP_IO_FLUSH, #SOAP_IO_BUFFER, #SOAP_IO_CHUNK
#define | SOAP_IO_CHUNK 0x00000003
| soap_mode IO output flag value to send HTTP chunked messages, buffers the message in packets of size #SOAP_BUFLEN, do not combine this flag with #SOAP_IO_FLUSH, #SOAP_IO_BUFFER, #SOAP_IO_STORE
#define | SOAP_IO_UDP 0x00000004
| soap_mode IO input/output flag value to use UDP datagrams, message size is limited to UDP packet size
#define | SOAP_IO_LENGTH 0x00000008
| soap_mode IO output flag value to calculate message length when sending a message without transmission (for internal use only)
#define | SOAP_IO_KEEPALIVE 0x00000010
| soap_mode IO input and output flag value to keep the socket connection alive for #SOAP_MAXKEEPALIVE message exchanges per connection (100 by default), enabling HTTP keep-alive connection persistence
#define | SOAP_ENC 0x00000FFF
| soap_mode ENC flags mask (for internal use only)
#define | SOAP_ENC_LATIN 0x00000020
| soap_mode ENC input flag value to receive ISO-8859-1 encoded messages (automatically detected when receiving XML)
#define | SOAP_ENC_PLAIN 0x00000040
| soap_mode ENC input/output flag value to omit the HTTP headers from messages sent and disable detection and parsing of HTTP headers in messages received
#define | SOAP_ENC_XML
| soap_mode ENC input/output flag (deprecated, same as #SOAP_ENC_PLAIN for backward compatibility)
#define | SOAP_ENC_DIME 0x00000080
| soap_mode ENC output flag value to enable DIME attachments (for internal use only)
#define | SOAP_ENC_MIME 0x00000100
| soap_mode ENC output flag value to enable MIME attachments in messages to be sent, receiving is automatic
#define | SOAP_ENC_MTOM 0x00000200
| soap_mode ENC output flag value to enable MTOM XOP attachments in messages to be sent, receiving is automatic
#define | SOAP_ENC_ZLIB 0x00000400
| soap_mode ENC output flag value to compress messages sent, requires zlib enabled with compile-time flag #WITH_GZIP (or #WITH_ZLIB for compression limited to "compress"), detection of compressed messages received and decompression of the messages is automatic
#define | SOAP_ENC_SSL 0x00000800
| soap_mode ENC input/output flag value to enable TLS/SSL, e.g. HTTPS, requires OpenSSL, GNUTLS or WolfSSL enabled with compile-time flag #WITH_OPENSSL, #WITH_GNUTLS, or #WITH_WOLFSSL (flag for internal use only)
#define | SOAP_XML_STRICT 0x00001000
| soap_mode XML input flag value to enable strict XML validation of messages received
#define | SOAP_XML_INDENT 0x00002000
| soap_mode XML output flag value to enable XML (and JSON) message indentation in messages sent
#define | SOAP_XML_IGNORENS 0x00004000
| soap_mode XML input flag value to ignore XML namespaces in messages received
#define | SOAP_XML_DEFAULTNS 0x00008000
| soap_mode XML output flag value to send XML messages with XML default namespaces for elements instead of namespace-qualified elements
#define | SOAP_XML_CANONICAL 0x00010000
| soap_mode XML output flag value to send XML messages in exclusive canonical format as per W3C XML C14N standards, use with the soap::c14ninclude and soap::c14nexclude strings to control the prefixes that are subject to canonicalization by including or excluding specific prefixes
#define | SOAP_XML_CANONICAL_NA 0x00800000
| soap_mode XML output flag value to send XML messages in exclusive canonical format as per W3C XML C14N standards, use with the soap::c14ninclude and soap::c14nexclude strings to control the prefixes that are subject to canonicalization by including or excluding specific prefixes
#define | SOAP_XML_TREE 0x00020000
| soap_mode XML input/output flag value to serialize C/C++ data structures as XML trees without id-href or id-ref multi-references and ignores these attributes during deserialization.
#define | SOAP_XML_GRAPH 0x00020000
| soap_mode XML input/output flag value to serialize C/C++ (cyclic) data structures in XML with id-ref references for co-referenced data and to accurately serialize data structure cycles, accept id-ref references in XML received to (re)construct the C/C++ (co-referenced and cyclic) data structures,
#define | SOAP_XML_NIL 0x00040000
| soap_mode XML output flag value to serialize C/C++ NULL pointers in XML as elements with attribute xsi:nil="true"
#define | SOAP_XML_NOTYPE 0x00080000
| soap_mode XML output flag value to serialize C/C++ data structures in XML without xsi:type attributes, even when this may be necessary to distinguish base from derived data types
#define | SOAP_XML_DOM 0x10000000
| soap_mode XML input/output flag value to enable DOM node tree construction of the XML received and sent, requires compile-time flag #WITH_DOM
#define | SOAP_DOM_ASIS 0x00400000
| soap_mode DOM output flag value to disable reformatting of the DOM node tree in XML, displaying the DOM in XML exactly as is
#define | SOAP_DOM_NODE 0x00200000
| soap_mode DOM input flag value to always attempt to deserialize embedded serializable C/C++ data structures into the DOM node tree based on matching element name to C/C++ type names and by matching xsi:type attributes when present, the opposite of #SOAP_DOM_TREE
#define | SOAP_DOM_TREE 0x00100000
| soap_mode DOM input flag value to ignore id and xsi:type XML attributes and disables deserialization of serializable C/C++ data structures into the DOM node tree, the opposite of #SOAP_DOM_NODE
#define | SOAP_C_NOIOB 0x01000000
| soap_mode input flag value to ignore array items that are out of bounds when deserializing fixed-size arrays, instead of producing #SOAP_IOB errors
#define | SOAP_C_UTFSTRING 0x02000000
| soap_mode input/output flag value to serialize and deserialize 8-bit C/C++ strings containing UTF-8 encoded Unicode characters
#define | SOAP_C_MBSTRING 0x04000000
| soap_mode input/output flag value to enable multibyte character support for 8-bit character strings with wctomb and mbtowc using the current locale
#define | SOAP_C_NILSTRING 0x08000000
| soap_mode input/output flag value to serialize empty strings as elements with attribute xsi:nil="true"
#define | SOAP_MIME_POSTCHECK 0x40000000
| soap_mode MIME input flag value to check and process additional MIME attachments (for internal use only)
#define | SOAP_SEC_WSUID 0x80000000
| soap_mode SEC output flag value to add wsu:Id attributes to signed parts of messages sent and signed with WS-Security (for internal use only)
#define | SOAP_OK
| The soap_status code for no error (zero).
#define | SOAP_CLI_FAULT
| A soap_status error code: the service returned a SOAP 1.1 client fault / SOAP 1.2 sender fault to the client.
#define | SOAP_DATAENCODINGUNKNOWN
| A soap_status error code: SOAP 1.2 DataEncodingUnknown fault (unused in practice).
#define | SOAP_DIME_ERROR
| A soap_status error code: DIME formatting error or DIME attachment size exceeds #SOAP_MAXDIMESIZE.
#define | SOAP_DIME_HREF
| A soap_status error code: DIME attachment has no href from SOAP body and no DIME callbacks were defined to save the attachment.
#define | SOAP_DIME_MISMATCH
| A soap_status error code: DIME version error.
#define | SOAP_DIME_END
| A soap_status error code: end of DIME attachments protocol error.
#define | SOAP_DUPLICATE_ID
| A soap_status error code: XML element has duplicate id attribute value (applicable to SOAP multi-ref encoding and #SOAP_XML_GRAPH serialization).
#define | SOAP_EMPTY
| A soap_status error code: XML element or attribute is empty when a value is required.
#define | SOAP_END_TAG
| A soap_status error code: XML ending tag found when none was expected.
#define | SOAP_EOF
| A soap_status error code: unexpected end of file, no input, transmission interrupted or timed out (same value as EOF).
#define | SOAP_EOM
| A soap_status error code: out of memory.
#define | SOAP_ERR
| A soap_status error code: an unspecified error occurred.
#define | SOAP_FAULT
| A soap_status error code: the fault code to be returned by a service operation when calling soap_sender_fault (client is at fault) or soap_receiver_fault (server is at fault), and when received, clients set the soap::error code to #SOAP_CLI_FAULT or #SOAP_SVR_FAULT respectively.
#define | SOAP_FD_EXCEEDED
| A soap_status error code: too many open sockets.
#define | SOAP_FIXED
| A soap_status error code: XML element or attribute value is fixed and the parsed value does not match the fixed value.
#define | SOAP_GET_METHOD
| A soap_status error code: an HTTP GET request was received by the service but the GET request callback soap::fget is not implemented.
#define | SOAP_PUT_METHOD
| A soap_status error code: an HTTP PUT request was received by the service but the PUT request callback soap::fput is not implemented.
#define | SOAP_PATCH_METHOD
| A soap_status error code: an HTTP PATCH request was received by the service but the PATCH request callback soap::fpatch is not implemented.
#define | SOAP_DEL_METHOD
| A soap_status error code: an HTTP DELETE request was received by the service but the DELETE request callback soap::fdel is not implemented.
#define | SOAP_HTTP_METHOD
| A soap_status error code: an HTTP request was received by the service that cannot be handled.
#define | SOAP_HDR
| A soap_status error code: HTTP header line is too long, exceeding #SOAP_HDRLEN size.
#define | SOAP_HREF
| A soap_status error code: reference to object in XML identified by its id attribute is incompatible with the object refered to by the ref or href attribute (applicable to SOAP multi-ref encoding and #SOAP_XML_GRAPH serialization).
#define | SOAP_HTTP_ERROR
| A soap_status error code: an unspecified HTTP error occured.
#define | SOAP_IOB
| A soap_status error code: SOAP array index out of bounds.
#define | SOAP_LENGTH
| A soap_status error code: XML element or attribute value length validation error or #SOAP_MAXLENGTH exceeded.
#define | SOAP_LEVEL
| A soap_status error code: XML nesting depth level when parsing XML exceeds #SOAP_MAXLEVEL.
#define | SOAP_MIME_END
| A soap_status error code: end of MIME/MTOM attachments protocol error.
#define | SOAP_MIME_ERROR
| A soap_status error code: MIME/MTOM attachment parsing error.
#define | SOAP_MIME_HREF
| A soap_status error code: MIME/MTOM attachment has no href from SOAP body and no MIME callbacks were defined to save the attachment.
#define | SOAP_MISSING_ID
| A soap_status error code: an XML element with id attribute is missing that should match the element with href/ref attribute (applicable to SOAP multi-ref encoding and #SOAP_XML_GRAPH serialization).
#define | SOAP_MOE
| A soap_status error code: heap memory overflow or corruption error, which can never happen in gSOAP unless the application code itself caused memory instability e.g. the heap is trashed.
#define | SOAP_MUSTUNDERSTAND
| A soap_status error code: an XML element is present with a mustUnderstand attribute which must be understood but is not deserialized.
#define | SOAP_NAMESPACE
| A soap_status error code: XML namespace name mismatch validation error.
#define | SOAP_NO_DATA
| A soap_status error code: no data in the HTTP body of the message received.
#define | SOAP_NO_METHOD
| A soap_status error code: the service request dispatcher did not find a matching service operation for a service request.
#define | SOAP_NO_TAG
| A soap_status error code: no XML element tag was found when one was expected.
#define | SOAP_NTLM_ERROR
| A soap_status error code: an NTLM authentication handshake error occured.
#define | SOAP_NULL
| A soap_status error code: XML element has an xsi:nil attribute when the element is not nillable, causing a validation error.
#define | SOAP_OCCURS
| A soap_status error code: XML element has a minOccurs or maxOccurs constraint validation error or #SOAP_MAXOCCURS was exceeded.
#define | SOAP_PATTERN
| A soap_status error code: XML element or attribute value pattern mismatch causes a validation error.
#define | SOAP_PLUGIN_ERROR
| A soap_status error code: failed to register plugin.
#define | SOAP_PROHIBITED
| A soap_status error code: attribute is prohibited but present.
#define | SOAP_PUT_METHOD
| A soap_status error code: an HTTP PUT request was received by the service but the PUT request callback soap::fput is not implemented.
#define | SOAP_REQUIRED
| A soap_status error code: attribute is required but not present.
#define | SOAP_SSL_ERROR
| A soap_status error code: an SSL error occured.
#define | SOAP_SVR_FAULT
| A soap_status error code: service returned a SOAP 1.1 server fault / SOAP 1.2 receiver fault to the client.
#define | SOAP_SYNTAX_ERROR
| A soap_status error code: an XML syntax error occurred while parsing the input.
#define | SOAP_TAG_MISMATCH
| A soap_status error code: XML element tag parsed does not match anything that is expected.
#define | SOAP_TCP_ERROR
| A soap_status error code: a TCP/IP connection error occured.
#define | SOAP_TYPE
| A soap_status error code: XML element or attribute has a mismatching type or value that is causing a validation error.
#define | SOAP_UDP_ERROR
| A soap_status error code: a UDP/IP connection error occured or the message too large to store in a UDP packet.
#define | SOAP_USER_ERROR
| A soap_status error code: soap::user not set to non-NULL.
#define | SOAP_UTF_ERROR
| A soap_status error code: a UTF-8 decoding error occured.
#define | SOAP_VERSIONMISMATCH
| A soap_status error code: SOAP version mismatch or no SOAP message is received.
#define | SOAP_ZLIB_ERROR
| A soap_status error code: a zlib error occured.
#define | soap_xml_error_check(e)
| Check for XML parsing and validation errors, returns true if the specified error code is an XML error.
#define | soap_soap_error_check(e)
| Check for SOAP protocol faults and errors, returns true if the specified error code is a SOAP protocol error.
#define | soap_http_error_check(e)
| Check for HTTP protocol errors, returns true if the specified error code is an HTTP protocol error or an HTTP status code between 100 and 599 returned by an HTTP server, but note that HTTP status 100 to 202 should not be considered errors but informative codes.
#define | soap_dime_error_check(e)
| Check for DIME protocol errors, returns true if the specified soap_status error code is a DIME protocol error.
#define | soap_mime_error_check(e)
| Check for MIME/MTOM protocol errors, returns true if the specified soap_status error code is a MIME/MTOM protocol error.
#define | soap_tcp_error_check(e)
| Check for TCP protocol errors, returns true if the specified error code is a TCP error, when true use soap::errnum to retrieve the errno value of the failure to determine the cause.
#define | soap_udp_error_check(e)
| Check for UDP protocol errors, returns true if the specified error code is a UDP error, when true use soap::errnum to retrieve the errno value of the failure to determine the cause.
#define | soap_ssl_error_check(e)
| Check for SSL/TLS protocol errors, returns true if the specified error code is a SSL/TLS error, when true use soap::errnum to retrieve the errno value of the failure to determine the cause.
#define | soap_zlib_error_check(e)
| Check for zlib library errors, returns true if the specified error code is a zlib error.
#define | SOAP_STOP
| An internal soap_status error code to signal that an HTTP response must not be produced.
#define | SOAP_FORM
| An internal soap_status error code to signal that an HTTP form is present and no HTTP response must be produced.
#define | SOAP_HTML
| A special soap_status error code to signal that a custom HTTP response is present and no HTTP response must be produced.
#define | SOAP_FILE
| A special soap_status error code to signal that a custom file-based HTTP response is present and no HTTP response must be produced.
#define | SOAP_SSL_DEFAULT (SOAP_SSL_REQUIRE_SERVER_AUTHENTICATION | SOAP_TLSv1)
#define | SOAP_SSL_ALLOW_EXPIRED_CERTIFICATE
#define | SOAP_SSL_NO_AUTHENTICATION
#define | SOAP_SSL_NO_DEFAULT_CA_PATH
#define | SOAP_SSL_REQUIRE_CLIENT_AUTHENTICATION
#define | SOAP_SSL_REQUIRE_SERVER_AUTHENTICATION
#define | SOAP_SSL_RSA
#define | SOAP_SSL_SKIP_HOST_CHECK
#define | SOAP_SSL_SNI_HOST_CHECK
#define | SOAP_SSLv3
#define | SOAP_SSLv3_TLSv1
#define | SOAP_TLSv1
#define | SOAP_TLSv1_0
#define | SOAP_TLSv1_1
#define | SOAP_TLSv1_2
#define | SOAP_TLSv1_3
#define | SOAP_POST
#define | SOAP_POST_FILE
#define | SOAP_GET
#define | SOAP_PUT
#define | SOAP_DEL
#define | SOAP_CONNECT
#define | SOAP_HEAD
#define | SOAP_OPTIONS
#define | SOAP_PATCH
#define | THREAD_TYPE
| Type of a thread (thread ID).
#define | THREAD_ID
| The thread ID of self.
#define | THREAD_CREATE(tidptr, funcptr, argptr)
| Create a new thread.
#define | THREAD_CREATEX(tidptr, funcptr, argptr)
| Create a new joinable thread (Windows only).
#define | THREAD_CLOSE(tid)
| Close the thread ID handle created by #THREAD_CREATEX (Windows only).
#define | THREAD_DETACH(tid)
| Detach a thread.
#define | THREAD_JOIN(tid)
| Join a thread.
#define | THREAD_EXIT
| Exit the current thread.
#define | THREAD_CANCEL(tid)
| Cancel a thread.
#define | MUTEX_TYPE
| Type of a mutex object.
#define | MUTEX_INITIALIZER
| Mutex initializer object.
#define | MUTEX_SETUP(mx)
| Mutex object initialization.
#define | MUTEX_CLEANUP(mx)
| Mutex object finalization.
#define | MUTEX_LOCK(mx)
| Mutex object lock.
#define | MUTEX_TRYLOCK(mx)
| Mutex object try lock attempt to lock.
#define | MUTEX_UNLOCK(mx)
| Mutex object unlock.
#define | COND_TYPE
| The type of a condition variable.
#define | COND_SETUP(cv)
| Condition variable initialization.
#define | COND_CLEANUP(cv)
| Condition variable finalization.
#define | COND_SIGNAL(cv)
| Condition variable signal operation.
#define | COND_WAIT(mx, cv)
| Condition variable wait operation.
#define | SOAP_OK
| The soap_status code for no error (zero).

## Typedefs

typedef int | soap_mode
| The soap_mode flags to initialize the soap context, flags can be combined with | (bit-wise or).
typedef int | soap_status
| Status and error codes are int values, a zero value or #SOAP_OK (0) means no error, nonzero means error.
typedef int | soap_status
| Status and error codes are int values, a zero value or #SOAP_OK (0) means no error, nonzero means error.

## Enumerations

enum | soap_mime_encoding { SOAP_MIME_NONE , SOAP_MIME_7BIT , SOAP_MIME_8BIT , SOAP_MIME_BINARY , SOAP_MIME_QUOTED_PRINTABLE , SOAP_MIME_BASE64 , SOAP_MIME_IETF_TOKEN , SOAP_MIME_X_TOKEN }
| RFC2045 MIME content transfer encodings. More...

## Functions

void | soap_set_recv_logfile (struct soap *soap, const char *logfile)
| Specify a file name to save messages received.
void | soap_set_sent_logfile (struct soap *soap, const char *logfile)
| Specify a file name to save messages sent.
void | soap_set_test_logfile (struct soap *soap, const char *logfile)
| Specify a file name to save debugging info.
void | soap_set_logging_inbound (struct soap *soap, FILE *fd)
| Specify inbound message logging with the logging plugin.
void | soap_set_logging_outbound (struct soap *soap, FILE *fd)
| Specify outbound message logging with the logging plugin.
void | soap_logging_stats (struct soap *soap, size_t *sent, size_t *recv)
| Collect messaging statistics with the logging plugin.
void | soap_reset_logging_stats (struct soap *soap)
| Reset messaging statistics with the logging plugin.
int | logging (struct soap *, struct soap_plugin *, void *)
| The logging plugin registration function.

*Allocate and initialize a new ::soap context struct soap *soap_new *() * @returns pointer to allocated and initialized ` Allocate and initialize a new ::soap context with input and output ::soap_mode flags struct soap *soap_new1 *(soap_mode input_and_output_mode) * @returns pointer to allocated and initialized ` Allocate and initialize a new ::soap context with separate input and output ::soap_mode flags struct soap *soap_new2 *(soap_mode input_mode, soap_mode output_mode) * @returns pointer to allocated and initialized ` Initialize a stack allocated ::soap context void

soap_init (struct soap *soap)

*Initialize a stack allocated ::soap context with input and output ::soap_mode flags void | soap_init1 (struct soap *soap, soap_mode input_and_output_mode)
*Initialize a stack allocated ::soap context with input and output ::soap_mode flags void | soap_init2 (struct soap *soap, soap_mode input_mode, soap_mode output_mode)
*Set input and output ::soap_mode flags of the given ::soap context void | soap_set_mode (struct soap *soap, soap_mode input_and_output_mode)
*Set input ::soap_mode flags of the given ::soap context void | soap_set_imode (struct soap *soap, soap_mode input_mode)
*Set output ::soap_mode flags of the given ::soap context void | soap_set_omode (struct soap *soap, soap_mode output_mode)
*Clear input and output ::soap_mode flags of the given ::soap context void | soap_clr_mode (struct soap *soap, soap_mode input_and_output_mode)
*Clear input ::soap_mode flags of the given ::soap context void | soap_clr_imode (struct soap *soap, soap_mode input_mode)
*Clear output ::soap_mode flags of the given ::soap context void | soap_clr_omode (struct soap *soap, soap_mode output_mode)
*Copy the input output stream state of the given ::soap context to another context void | soap_copy_stream (struct soap *soap_destination, struct soap *soap_source)
*Free the input output stream state of the given ::soap context void | soap_free_stream (struct soap *soap)
*Finalize and free the given ::soap context from unmanaged heap memory void | soap_free (struct soap *soap)
*Finalize the given ::soap i e when the ::soap context is stack automatically invoked in C by the ::soap destructor on the ::soap context to delete void | soap_done (struct soap *soap)
*Allocate a block of heap memory managed by the specified ::soap context void * | soap_malloc (struct soap *soap, size_t len) * @returns pointer to the allocated block of memory or NULL on failure to allocate(out of memory)
*Copy a string to managed memory char * | soap_strdup (struct soap *soap, const char *string) * @returns copy of string or NULL when the specified string is NULL or on failure to allocate(out of memory)
*Copy a wide string to managed memory wchar_t * | soap_wstrdup (struct soap *soap, const wchar_t *string) * @returns copy of wide string or NULL when the specified wide string is NULL or on failure to allocate(out of memory)
*Unlink a block of heap memory allocated and managed by the specified ::soap this block of heap memory should be released explicitly later by the application int | soap_unlink (struct soap *soap, const void *ptr) * @returns `
*Delete all dynamically allocated C objects managed by the specified ::soap | context (deprecated since 2.8.140 and greater, `::soap_end` also deletes managed C++objects) void soap_destroy(struct soap *soap)
| < soap context
*Explicitly dealllocates a block of managed memory that is managed by the specified ::soap context and release the free memory back to the heap int | soap_dealloc (struct soap *soap, void *ptr) * @returns `
*Explicitly dealllocates a block of managed memory that is managed by the specified ::soap context and release the free memory back to the this function is idential to the ::soap_dealloc function int | soap_delete (struct soap *soap, void *ptr) * @returns `
*Delete temporary data void | soap_free_temp (struct soap *soap)
*Delete all data from heap memory managed by the specified ::soap context and release the freed memory back to the heap int | soap_end (struct soap *soap) * @returns `
*Delegate the deletion of all managed objects and data from the specified ::soap context to another ::soap context void | soap_delegate_deletion (struct soap *soap, struct soap *soap_to)
*Set SOAP | version (0=no SOAP, 1=SOAP 1.1, 2=SOAP 1.2) void soap_set_version(struct soap *soap
*::soap_ssl_flags flag value to use RSA instead of DH *(automatically set when no DH parameter is specified) *` Do not initalized the SSL TLS library void | soap_ssl_noinit (void)
*Initialize the server side SSL TLS context int | soap_ssl_server_context (struct soap *soap, soap_ssl_flags flags, const char *keyfile, const char *password, const char *cafile, const char *capath, const char *dhfile, const char *randfile, const char *sid) * @returns `
*Initialize the client side SSL TLS context int | soap_ssl_client_context (struct soap *soap, soap_ssl_flags flags, const char *keyfile, const char *password, const char *cafile, const char *capath, const char *randfile) * @returns `
*Enable SSL TLS CRLs int | soap_ssl_crl (struct soap *soap, const char *crlfile) * @returns `
*Accept SSL TLS connection int | soap_ssl_accept (struct soap *soap) * @returns `
*Setup function for OpenSSL versions prior to to set locks for multi threaded SSL TLS applications int | CRYPTO_thread_setup ()
*Cleanup function for OpenSSL versions prior to int | CRYPTO_thread_cleanup ()
*HTTP GET content from server int | soap_GET (struct soap *soap, const char *endpoint, const char *action) * @returns `
*HTTP PUT content to server int | soap_PUT (struct soap *soap, const char *endpoint, const char *action, const char *type) * @returns `
*HTTP PATCH content to server int | soap_PATCH (struct soap *soap, const char *endpoint, const char *action, const char *type) * @returns `
*HTTP POST content to server int | soap_POST (struct soap *soap, const char *endpoint, const char *action, const char *type) * @returns `
*HTTP DELETE content from server int | soap_DELETE (struct soap *soap, const char *endpoint) * @returns `
*Connect to a server int | soap_connect_command (struct soap *soap, soap_http_command http_command, const char *endpoint, const char *action) * @returns `
*Initiates serving a pending client request int | soap_begin_serve (struct soap *soap) * @returns `
*Process a pending request int | soap_serve_request (struct soap *soap) * @returns `
*Initialize the context for server side sending and send a HTTP response header int | soap_response (struct soap *soap, int status) * @returns `
*Initialize the context for receiving int | soap_begin_recv (struct soap *soap) * @returns `
*Finalize the context after receiving int | soap_end_recv (struct soap *soap) * @returns `
*Initialize the context for sending int | soap_begin_send (struct soap *soap) * @returns `
*Finalize the context after sending int | soap_end_send (struct soap *soap) * @returns `
*Initialize context to count message length for sending int | soap_begin_count (struct soap *soap) * @returns `
*Finalize context to count message length for sending int | soap_end_count (struct soap *soap) * @returns `
*Send a string int | soap_send (struct soap *soap, const char *s) * @returns `
*Send raw bytes int | soap_send_raw (struct soap *soap, const char *s, size_t n) * @returns `
*Check if HTTP body message is not empty int | soap_http_has_body (struct soap *soap) * @returns nonzero if an HTTP body is present
*Get the HTTP body message as a string char * | soap_http_get_body (struct soap *soap, size_t *len) * @returns HTTP body as a string or NULL when an error occurred
*Get a header line int | soap_getline (struct soap *soap, char *buf, int len) * @returns `
*Get next byte without consuming it soap_wchar | soap_get0 (struct soap *soap) * @returns byte read or EOF when an error occurred
*Get next byte soap_wchar | soap_get1 (struct soap *soap) * @returns byte read or EOF when an error occurred
*Poll the connection int | soap_poll (struct soap *soap) * @returns `
*Check if the connection is ready to receive pending data int | soap_ready (struct soap *soap) * @returns `
*Receive an HTTP response message from the server that is assumed to be empty int | soap_recv_empty_response (struct soap *soap) * @returns `
*Return an HTTP response message with an empty HTTP body from a service back to the client or peer int | soap_send_empty_response (struct soap *soap, int status) * @returns `
*Parse the XML< i >< SOAP-ENV:Envelope ></i > element opening tag if present int | soap_envelope_begin_in (struct soap *soap)
*Parse the XML< i ></SOAP-ENV:Envelope ></i > element closing tag if present int | soap_envelope_end_in (struct soap *soap) * @returns `
*Emit the XML< i >< SOAP-ENV:Envelope ></i > element opening tag if ::soap::version is nonzero int | soap_envelope_begin_out (struct soap *soap) * @returns `
*Emit the XML< i ></SOAP-ENV:Envelope ></i > element closing tag if ::soap::version is nonzero int | soap_envelope_end_out (struct soap *soap) * @returns `
*Parse the XML< i >< SOAP-ENV:Body ></i > element opening tag if present int | soap_body_begin_in (struct soap *soap) * @returns `
*Parse the XML< i ></SOAP-ENV:Body ></i > element closing tag if present int | soap_body_end_in (struct soap *soap) * @returns `
*Emit the XML< i >< SOAP-ENV:Body ></i > element opening tag if ::soap::version is nonzero int | soap_body_begin_out (struct soap *soap) * @returns `
*Emit the XML< i ></SOAP-ENV:Body ></i > element closing tag if ::soap::version is nonzero int | soap_body_end_out (struct soap *soap) * @returns `
*Emit the SOAP Header pointed to by ::soap::header int | soap_putheader (struct soap *soap) * @returns `
*Serialize the SOAP Header pointed to by ::soap::header before emitting it with ::soap_putheader void | soap_serializeheader (struct soap *soap)
*The HTTP GET plugin registration function int | http_get (struct soap *, struct soap_plugin *, void *)
void | soap_http_get_stats (struct soap *soap, size_t *stat_get, size_t *stat_post, size_t *stat_fail, size_t **hist_min, size_t **hist_hour, size_t **hist_day)
| Collect access statistics with the http_get plugin.
char * | soap_query (struct soap *soap)
| Extract the query string from the URL path at the server side with the http_get plugin.
char * | soap_query_key (struct soap *soap, char **query)
| Extract the next query string key at the server side with the http_get plugin.
char * | soap_query_val (struct soap *soap, char **query)
| Extract the next query string value at the server side with the http_get plugin.
int | http_post (struct soap *, struct soap_plugin *, void *)
| The HTTP POST plugin registration function.
int | http_form (struct soap *, struct soap_plugin *, void *)
| The HTTP FORM plugin registration function.
char * | soap_http_get_form (struct soap *soap)
| Get the HTTP POST application/x-www-form-urlencoded data as a string.
int | http_pipe (struct soap *, struct soap_plugin *, void *)
| The HTTP pipelining plugin registration function.
struct soap_cookie * | soap_set_cookie (struct soap *soap, const char *name, const char *value, const char *domain, const char *path)
| Add a cookie.
int | soap_set_cookie_expire (struct soap *soap, const char *name, long maxage, const char *domain, const char *path)
| Set cookie expiration.
int | soap_set_cookie_secure (struct soap *soap, const char *name, const char *domain, const char *path)
| Set cookie secure.
int | soap_set_cookie_session (struct soap *soap, const char *name, const char *domain, const char *path)
| Set session cookie.
void | soap_clr_cookie (struct soap *soap, const char *name, const char *domain, const char *path)
| Clear cookie.
int | soap_clr_cookie_session (struct soap *soap, const char *name, const char *domain, const char *path)
| Clear session cookie.
struct soap_cookie * | soap_cookie (struct soap *soap, const char *name, const char *domain, const char *path)
| Find a cookie.
const char * | soap_cookie_value (struct soap *soap, const char *name, const char *domain, const char *path)
| Get cookie value.
time_t | soap_cookie_expire (struct soap *soap, const char *name, const char *domain, const char *path)
| Get cookie expiration.
int | soap_getenv_cookies (struct soap *soap)
| Get cookies from the HTTP_COOKIE environment variable.
void | soap_free_cookies (struct soap *soap)
| Free cookies.
int | soap_s2byte (struct soap *soap, const char *string, char *value)
| Convert a decimal string to a signed 8 bit byte (char) integer value.
int | soap_s2short (struct soap *soap, const char *string, short *value)
| Convert a decimal string to a signed 16 bit integer value.
int | soap_s2int (struct soap *soap, const char *string, int *value)
| Convert a decimal string to a signed 32 bit integer value.
int | soap_s2long (struct soap *soap, const char *string, long *value)
| Convert a decimal string to a signed long integer value.
int | soap_s2LONG64 (struct soap *soap, const char *string, LONG64 *value)
| Convert a decimal string to a signed 64 bit integer value.
int | soap_s2float (struct soap *soap, const char *string, float *value)
| Convert a decimal string to a float value.
int | soap_s2double (struct soap *soap, const char *string, double *value)
| Convert a decimal string to a double float value.
int | soap_s2unsignedByte (struct soap *soap, const char *string, unsigned char *value)
| Convert a decimal string to an unsigned 8 bit byte (unsigned char) integer value.
int | soap_s2unsignedShort (struct soap *soap, const char *string, unsigned short *value)
| Convert a decimal string to an unsigned 16 bit integer value.
int | soap_s2unsignedInt (struct soap *soap, const char *string, unsigned int *value)
| Convert a decimal string to an unsigned 32 bit integer value.
int | soap_s2unsignedLong (struct soap *soap, const char *string, unsigned long *value)
| Convert a decimal string to an unsigned long integer value.
int | soap_s2ULONG64 (struct soap *soap, const char *string, ULONG64 *value)
| Convert a decimal string to an unsigned 64 bit integer value.
int | soap_s2char (struct soap *soap, const char *string, char **value, int flag, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new string while converting and validating the string contents.
int | soap_s2stdchar (struct soap *soap, const char *string, std::string *value, int flag, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new string while converting and validating the string contents.
int | soap_s2wchar (struct soap *soap, const char *string, wchar_t **value, int flag, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new wide string while converting and validating the string contents.
int | soap_s2stdwchar (struct soap *soap, const char *string, std::wstring *value, int flag, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new wide string while converting and validating the string contents.
int | soap_s2QName (struct soap *soap, const char *string, char **value, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new QName string while normalizing and validating the string contents.
int | soap_s2stdQName (struct soap *soap, const char *string, std::string *value, long minlen, long maxlen, const char *pattern)
| Copy a string (ASCII or UTF-8) to a new QName string while normalizing and validating the string contents.
int | soap_s2dateTime (struct soap *soap, const char *string, time_t *value)
| Convert a string with xsd:dateTime contents to a time_t value.
char * | soap_s2base64 (struct soap *soap, const unsigned char *data, char *base64, int len)
| Encode binary data as a base64-formatted string.
char * | soap_s2hex (struct soap *soap, const unsigned char *data, char *hex, int len)
| Encode binary data as a hex-formatted string.
const char * | soap_byte2s (struct soap *soap, char value)
| Convert a signed 8 bit byte (char) integer to a decimal string.
const char * | soap_short2s (struct soap *soap, short value)
| Convert a signed 16 bit integer to a decimal string.
const char * | soap_int2s (struct soap *soap, int value)
| Convert a signed 32 bit integer to a decimal string.
const char * | soap_long2s (struct soap *soap, long value)
| Convert a signed long integer to a decimal string.
const char * | soap_LONG642s (struct soap *soap, LONG64 value)
| Convert a signed 64 bit integer to a decimal string.
const char * | soap_float2s (struct soap *soap, float value)
| Convert a float value to a decimal string.
const char * | soap_double2s (struct soap *soap, double value)
| Convert a double float value to a decimal string.
const char * | soap_unsignedByte2s (struct soap *soap, unsigned char value)
| Convert an unsigned 8 bit byte (char) integer to a decimal string.
const char * | soap_unsignedShort2s (struct soap *soap, unsigned short value)
| Convert an unsigned 16 bit integer to a decimal string.
const char * | soap_unsignedInt2s (struct soap *soap, unsigned int value)
| Convert an unsigned 32 bit integer to a decimal string.
const char * | soap_unsignedLong2s (struct soap *soap, unsigned long value)
| Convert an unsigned long integer to a decimal string.
const char * | soap_ULONG642s (struct soap *soap, ULONG64 value)
| Convert an unsigned 64 bit integer to a decimal string.
const char * | soap_wchar2s (struct soap *soap, const wchar_t *value)
| Convert a wide string to a UTF-8 encoded string.
const char * | soap_dateTime2s (struct soap *soap, time_t value)
| Convert a time_t value to a string with xsd:dateTime contents.
const char * | soap_base642s (struct soap *soap, const char *base64, char *data, size_t maxdatalen, int *datalen)
| Decode a base64-formatted string to binary data.
const char * | soap_hex2s (struct soap *soap, const char *hex, char *data, size_t maxdatalen, int *datalen)
| Decode a hex-formatted string to binary data.
int | soap_set_namespaces (struct soap *soap, const struct Namespace *namespaces)
| Activates an XML namespace table to generate and resolve xmlns namespace prefixes in XML messages.
void | soap_header (struct soap *soap)
| If soap::header is NULL then allocate SOAP_ENV__Header header and set soap::header to point to it.
void | soap_fault (struct soap *soap)
| If soap::fault is NULL then allocate SOAP_ENV__Fault header and set soap::fault to point to it.
int | soap_sender_fault (struct soap *soap, const char *faultstring, const char *faultdetail)
| Set SOAP 1.1 client fault / SOAP 1.2 sender fault string and detail.
int | soap_sender_fault_subcode (struct soap *soap, const char *faultsubcode, const char *faultstring, const char *faultdetail)
| Set SOAP 1.1 client fault / SOAP 1.2 sender fault subcode, string and detail.
int | soap_receiver_fault (struct soap *soap, const char *faultstring, const char *faultdetail)
| Set SOAP 1.1 server fault / SOAP 1.2 receiver fault string and detail.
int | soap_receiver_fault_subcode (struct soap *soap, const char *faultsubcode, const char *faultstring, const char *faultdetail)
| Set SOAP 1.1 server fault / SOAP 1.2 receiver fault subcode, string and detail.
void | soap_print_fault (struct soap *soap, FILE *fd)
| Print error message on the specified output.
void | soap_stream_fault (struct soap *soap, std::ostream &os)
| Print error message on the specified output stream.
char * | soap_sprint_fault (struct soap *soap, char *buf, size_t len)
| Print error message to the specified string buffer.
void | soap_print_fault_location (struct soap *soap, FILE *fd)
| Print the location in the message where and when the error occurred.
void | soap_stream_fault_location (struct soap *soap, std::ostream &os)
| Print the location in the message where and when the error occurred.
const char * | soap_fault_subcode (struct soap *soap)
| Returns the SOAP Fault subcode QName string or NULL when absent.
const char * | soap_fault_string (struct soap *soap)
| Returns the SOAP Fault string/reason or NULL when absent.
const char * | soap_fault_detail (struct soap *soap)
| Returns the SOAP Fault detail XML string or NULL when absent.
const char ** | soap_faultsubcode (struct soap *soap)
| Allocates and returns a pointer to the SOAP Fault subcode QName string to set this string.
const char ** | soap_faultstring (struct soap *soap)
| Allocates and returns a pointer to the SOAP Fault string/reason to set this string.
const char ** | soap_faultdetail (struct soap *soap)
| Allocates and returns a pointer to the SOAP Fault detail XML string to set this string or NULL when not accessible.
int | soap_set_dime (struct soap *soap)
| Enable DIME attachments.
void | soap_clr_dime (struct soap *soap)
| Disable DIME attachments.
int | soap_set_dime_attachment (struct soap *soap, const char *ptr, size_t size, const char *type, const char *id, unsigned short optype, const char *option)
| Add a DIME attachment to the SOAP/XML message.
char * | soap_dime_option (struct soap *soap, unsigned short optype, const char *option)
| Creates a DIME option.
int | soap_set_mime_attachment (struct soap *soap, const char *ptr, size_t size, enum soap_mime_encoding encoding, const char *type, const char *id, const char *location, const char *description)
| Add a MIME attachment to the SOAP/XML message.
int | soap_set_mime (struct soap *soap, const char *boundary, const char *start)
| Enable MIME attachments.
void | soap_clr_mime (struct soap *soap)
| Disable MIME attachments.
int | soap_post_check_mime_attachments (struct soap *soap)
| Enable post-processing of MIME/MTOM attachments.
int | soap_check_mime_attachments (struct soap *soap)
| Check for a MIME/MTOM attachment.
struct soap_multipart * | soap_recv_mime_attachment (struct soap *soap, void *handle)
| Get a MIME/MTOM attachment.
int | soap_register_plugin (struct soap *soap, int(*fcreate)(struct soap *, struct soap_plugin *, void *))
| Register a plugin.
int | soap_register_plugin_arg (struct soap *soap, int(*fcreate)(struct soap *, struct soap_plugin *, void *), void *arg)
| Register a plugin with an argument.
void | soap_begin (struct soap *soap)
| Reset context.
const char * | soap_rand_uuid (struct soap *soap, const char *prefix)
| Returns a randomized unique UUID string.
int | soap_tag_cmp (const char *string, const char *pattern)
| Compare string to a pattern.
int | soap_match_tag (struct soap *soap, const char *tag1, const char *tag2)
| Match an XML tag name.

## Variables

*A built in string type containing literal XML content in UTF format typedef char * | _XML
*A built in string type containing normalized QName contents typedef char * | _QName
*HTTP command methods for ::soap_connect_command typedef int | soap_http_command
*Wide char type typedef int32_t | soap_wchar
*Allocate and initialize a new ::soap context as a copy of the given ::soap context struct soap *soap_copy *(struct soap *soap) * @returns pointer to allocated and initialized ` Copy a given ::soap context to an uninitialized destination ::soap context voi | soap_copy_context )(struct soap *soap_destination, struct soap *soap_source)
*Finalize the given ::soap | context
*Finalize the given ::soap i e when the ::soap context is stack | allocated
*Explicitly dealllocates a block of managed memory that is managed by the specified ::soap context and release the free memory back to the | heap
*Set SOAP short | version
| < soap contexr
*Bind and listen to a port SOAP_SOCKET soap_bind *(struct soap *soap, const char *host, int port, int backlog) * @returns the ` Accept a connection with a client SOAP_SOCKET soap_accept *(struct soap *soap) * @returns the ` Serve a pending request in | soap_serve )(struct soap *soap) * @returns `
*Check if HTTP body message is not empty int zero | otherwise
*Parse and deserialize the SOAP Fault int soap_recv_fault *(struct soap *soap, int check) * @returns a nonzero ` Return an HTTP error with a SOAP Fault message from a service int soap_send_fault *(struct soap *soap) * @returns the value of ` Parse and deserialize the SOAP Header in | soap_recv_header )(struct soap *soap) * @returns `
struct Namespace | namespaces []
| The global XML namespaces table with entries defined by the Namespace structure and populated in an .nsmap file generated by soapcpp2.

## Detailed Description

This file defines the common macros, types and functions of the gSOAP API grouped by modules.

The API features are grouped by the following modules:

- Debugging and logging
- WITH_MACRO compile-time flags
- SOAP_MACRO compile-time values
- SOAP_MACRO run-time flags
- SOAP_MACRO run-time error codes
- Context with engine state
- Callback functions
- SSL/TLS context and functions
- HTTP and IO functions
- HTTP cookie functions
- Conversion functions
- XML namespace tables
- Header structure and functions
- Fault structure and functions
- DIME attachment functions
- MIME attachment functions
- Plugins and plugin registry functions
- Miscellaneous functions

## Macro Definition Documentation

## ◆ SOAP_OK

#define SOAP_OK

The soap_status code for no error (zero).

## ◆ SOAP_SSL_RSA

#define SOAP_SSL_RSA

## ◆ SOAP_SSL_SKIP_HOST_CHECK

#define SOAP_SSL_SKIP_HOST_CHECK

## ◆ SOAP_SSL_SNI_HOST_CHECK

#define SOAP_SSL_SNI_HOST_CHECK

## ◆ SOAP_SSLv3

#define SOAP_SSLv3

## ◆ SOAP_SSLv3_TLSv1

#define SOAP_SSLv3_TLSv1

## ◆ SOAP_TLSv1

#define SOAP_TLSv1

## ◆ SOAP_TLSv1_0

#define SOAP_TLSv1_0

## ◆ SOAP_TLSv1_1

#define SOAP_TLSv1_1

## ◆ SOAP_TLSv1_2

#define SOAP_TLSv1_2

## ◆ SOAP_TLSv1_3

#define SOAP_TLSv1_3

## Typedef Documentation

## ◆ soap_status

typedef int soap_status

Status and error codes are int values, a zero value or #SOAP_OK (0) means no error, nonzero means error.

The #SOAP_OK (zero) and nonzero error codes are returned by functions and are also stored in soap::error (soap::errnum stores the value of errno for system-related errors). A nonzero error code is one of the following error codes or a HTTP error code between 100 and 599 returned by the server when a client connects: #SOAP_CLI_FAULT #SOAP_DATAENCODINGUNKNOWN #SOAP_DEL_METHOD #SOAP_DIME_END #SOAP_DIME_ERROR #SOAP_DIME_HREF #SOAP_DIME_MISMATCH #SOAP_DUPLICATE_ID #SOAP_EMPTY #SOAP_END_TAG #SOAP_EOF (same as EOF) #SOAP_EOM #SOAP_ERR (same as EOF) #SOAP_FAULT #SOAP_FD_EXCEEDED #SOAP_FIXED #SOAP_GET_METHOD #SOAP_HDR #SOAP_HREF #SOAP_HTTP_ERROR #SOAP_HTTP_METHOD #SOAP_IOB #SOAP_LENGTH #SOAP_LEVEL #SOAP_MIME_END #SOAP_MIME_ERROR #SOAP_MIME_HREF #SOAP_MISSING_ID #SOAP_MOE #SOAP_MUSTUNDERSTAND #SOAP_NAMESPACE #SOAP_NO_DATA #SOAP_NO_METHOD #SOAP_NO_TAG #SOAP_NTLM_ERROR #SOAP_NULL #SOAP_OCCURS #SOAP_PATCH_METHOD #SOAP_PATTERN #SOAP_PLUGIN_ERROR #SOAP_PROHIBITED #SOAP_PUT_METHOD #SOAP_REQUIRED #SOAP_SSL_ERROR #SOAP_SVR_FAULT #SOAP_SYNTAX_ERROR #SOAP_TAG_MISMATCH #SOAP_TCP_ERROR #SOAP_TYPE #SOAP_UDP_ERROR #SOAP_USER_ERROR #SOAP_UTF_ERROR #SOAP_VERSIONMISMATCH #SOAP_ZLIB_ERROR

See also
  soap::error, soap_xml_error_check, soap_soap_error_check, soap_http_error_check, soap_dime_error_check, soap_mime_error_check, soap_tcp_error_check, soap_udp_error_check, soap_ssl_error_check, soap_zlib_error_check.