You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2780 lines
94 KiB

7 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. /*
  2. stdsoap2.h 2.8.17r
  3. gSOAP runtime engine
  4. gSOAP XML Web services tools
  5. Copyright (C) 2000-2013, Robert van Engelen, Genivia Inc., All Rights Reserved.
  6. This part of the software is released under ONE of the following licenses:
  7. GPL, or the gSOAP public license, or Genivia's license for commercial use.
  8. --------------------------------------------------------------------------------
  9. Contributors:
  10. Wind River Systems, Inc., for the following additions
  11. - vxWorks compatible
  12. --------------------------------------------------------------------------------
  13. gSOAP public license.
  14. The contents of this file are subject to the gSOAP Public License Version 1.3
  15. (the "License"); you may not use this file except in compliance with the
  16. License. You may obtain a copy of the License at
  17. http://www.cs.fsu.edu/~engelen/soaplicense.html
  18. Software distributed under the License is distributed on an "AS IS" basis,
  19. WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  20. for the specific language governing rights and limitations under the License.
  21. The Initial Developer of the Original Code is Robert A. van Engelen.
  22. Copyright (C) 2000-2013, Robert van Engelen, Genivia Inc., All Rights Reserved.
  23. --------------------------------------------------------------------------------
  24. GPL license.
  25. This program is free software; you can redistribute it and/or modify it under
  26. the terms of the GNU General Public License as published by the Free Software
  27. Foundation; either version 2 of the License, or (at your option) any later
  28. version.
  29. This program is distributed in the hope that it will be useful, but WITHOUT ANY
  30. WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  31. PARTICULAR PURPOSE. See the GNU General Public License for more details.
  32. You should have received a copy of the GNU General Public License along with
  33. this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  34. Place, Suite 330, Boston, MA 02111-1307 USA
  35. Author contact information:
  36. engelen@genivia.com / engelen@acm.org
  37. This program is released under the GPL with the additional exemption that
  38. compiling, linking, and/or using OpenSSL is allowed.
  39. --------------------------------------------------------------------------------
  40. A commercial use license is available from Genivia, Inc., contact@genivia.com
  41. --------------------------------------------------------------------------------
  42. */
  43. #define GSOAP_VERSION 20817
  44. #ifdef WITH_SOAPDEFS_H
  45. # include "soapdefs.h" /* include user-defined stuff */
  46. #endif
  47. #ifndef _THREAD_SAFE
  48. # define _THREAD_SAFE
  49. #endif
  50. #ifndef OPENSERVER
  51. # ifndef _REENTRANT
  52. # define _REENTRANT
  53. # endif
  54. #endif
  55. #ifndef SOAP_FMAC1 /* stdsoap2.h declaration macro */
  56. # define SOAP_FMAC1
  57. #endif
  58. #ifndef SOAP_FMAC2 /* stdsoap2.h declaration macro */
  59. # define SOAP_FMAC2
  60. #endif
  61. #ifndef SOAP_FMAC3 /* (de)serializer declaration macro */
  62. # define SOAP_FMAC3
  63. #endif
  64. #ifndef SOAP_FMAC3S /* string converter for (de)serializer declaration macro */
  65. # define SOAP_FMAC3S SOAP_FMAC3
  66. #endif
  67. #ifndef SOAP_FMAC4 /* (de)serializer declaration macro */
  68. # define SOAP_FMAC4
  69. #endif
  70. #ifndef SOAP_FMAC4S /* string converter for (de)serializer declaration macro */
  71. # define SOAP_FMAC4S SOAP_FMAC4
  72. #endif
  73. #ifndef SOAP_FMAC5 /* stub/skeleton declaration macro */
  74. # define SOAP_FMAC5
  75. #endif
  76. #ifndef SOAP_FMAC6 /* stub/skeleton declaration macro */
  77. # define SOAP_FMAC6
  78. #endif
  79. #ifndef SOAP_CMAC /* class declaration macro */
  80. # define SOAP_CMAC
  81. #endif
  82. #ifndef SOAP_NMAC /* namespace table declaration macro */
  83. # define SOAP_NMAC
  84. #endif
  85. #ifndef SOAP_SOURCE_STAMP
  86. # define SOAP_SOURCE_STAMP(str)
  87. #endif
  88. /* gSOAP 2.7.4 and higher: fast look-aside buffering is stable */
  89. #ifndef WITH_FAST
  90. # define WITH_FAST
  91. #endif
  92. #ifndef STDSOAP_H
  93. #define STDSOAP_H
  94. #if defined(__vxworks) || defined(__VXWORKS__)
  95. # ifndef VXWORKS
  96. # define VXWORKS
  97. # endif
  98. #endif
  99. #ifdef _WIN32
  100. # ifndef WIN32
  101. # define WIN32
  102. # endif
  103. #endif
  104. /* for legacy purposes we use WIN32 macro even though 64 bit is supported */
  105. #ifdef _WIN64
  106. # ifndef WIN32
  107. # define WIN32
  108. # endif
  109. #endif
  110. #ifdef _WIN32_WCE
  111. # ifndef UNDER_CE
  112. # define UNDER_CE _WIN32_WCE
  113. # endif
  114. #endif
  115. #ifdef UNDER_CE
  116. # ifndef WIN32
  117. # define WIN32
  118. # endif
  119. #endif
  120. #ifdef __BORLANDC__
  121. # ifdef __WIN32__
  122. # ifndef WIN32
  123. # define WIN32
  124. # endif
  125. # endif
  126. #endif
  127. #ifdef __CYGWIN__
  128. # ifndef CYGWIN
  129. # define CYGWIN
  130. # endif
  131. #endif
  132. #ifdef __SYMBIAN32__
  133. # define SYMBIAN
  134. # undef WIN32
  135. #endif
  136. #if defined(__palmos__) || defined(PALM_GCC) || defined(__PALMOS_TRAPS__)
  137. # ifndef PALM
  138. # define PALM
  139. # endif
  140. #endif
  141. #if defined(__hpux)
  142. # ifndef HP_UX
  143. # define HP_UX
  144. # endif
  145. #endif
  146. #if defined(__digital__) && defined(__unix__)
  147. # ifndef TRU64
  148. # define TRU64
  149. # endif
  150. #endif
  151. #ifdef __MVS__
  152. # ifndef OS390
  153. # define OS390
  154. # endif
  155. #endif
  156. #ifdef HAVE_CONFIG_H
  157. # include "config.h"
  158. # if defined(WITH_OPENSSL)
  159. # ifndef HAVE_OPENSSL_SSL_H
  160. # undef WITH_OPENSSL
  161. # endif
  162. # endif
  163. # if defined(WITH_GNUTLS)
  164. # ifndef HAVE_GNUTLS_GNUTLS_H
  165. # undef WITH_GNUTLS
  166. # endif
  167. # endif
  168. # if defined(WITH_ZLIB) || defined(WITH_GZIP)
  169. # ifndef HAVE_ZLIB_H
  170. # undef WITH_ZLIB
  171. # undef WITH_GZIP
  172. # endif
  173. # endif
  174. #else
  175. # if defined(UNDER_CE)
  176. # define WITH_LEAN
  177. # define HAVE_SSCANF
  178. # elif defined(WIN32)
  179. # if _MSC_VER >= 1400
  180. # define HAVE_SNPRINTF
  181. # endif
  182. # define HAVE_STRRCHR
  183. # define HAVE_STRTOD
  184. # define HAVE_SSCANF
  185. # define HAVE_STRTOD_L
  186. # define HAVE_SPRINTF_L
  187. # define HAVE_STRTOL
  188. # define HAVE_STRTOUL
  189. # if _MSC_VER >= 1300
  190. # define HAVE_STRTOLL /* use _strtoi64 */
  191. # define HAVE_STRTOULL /* use _strtoui64 */
  192. # endif
  193. # define HAVE_SYS_TIMEB_H
  194. # define HAVE_FTIME
  195. # define HAVE_GMTIME
  196. # define HAVE_WCTOMB
  197. # define HAVE_MBTOWC
  198. # define SOAP_LONG_FORMAT "%I64d"
  199. # define SOAP_ULONG_FORMAT "%I64u"
  200. # elif defined(CYGWIN)
  201. # define HAVE_POLL
  202. # define HAVE_SNPRINTF
  203. # define HAVE_STRRCHR
  204. # define HAVE_STRTOD
  205. # define HAVE_SSCANF
  206. # define HAVE_STRTOL
  207. # define HAVE_STRTOUL
  208. # define HAVE_SYS_TIMEB_H
  209. # define HAVE_FTIME
  210. # define HAVE_RAND_R
  211. # define HAVE_GMTIME_R
  212. # define HAVE_LOCALTIME_R
  213. # define HAVE_STRERROR_R
  214. # define HAVE_WCTOMB
  215. # define HAVE_MBTOWC
  216. # elif defined(__APPLE__)
  217. # define HAVE_POLL
  218. # define HAVE_SNPRINTF
  219. # define HAVE_STRRCHR
  220. # define HAVE_STRTOD
  221. # define HAVE_SSCANF
  222. # define HAVE_STRTOD_L
  223. # define HAVE_SSCANF_L
  224. # define HAVE_SPRINTF_L
  225. # define HAVE_STRTOL
  226. # define HAVE_STRTOUL
  227. # define HAVE_RAND_R
  228. # define HAVE_GMTIME_R
  229. # define HAVE_TM_GMTOFF
  230. # define HAVE_GETTIMEOFDAY
  231. # define HAVE_LOCALTIME_R
  232. # define HAVE_STRERROR_R
  233. # define HAVE_TIMEGM
  234. # define HAVE_WCTOMB
  235. # define HAVE_MBTOWC
  236. # define HAVE_INTTYPES_H
  237. # elif defined(_AIX43)
  238. # define HAVE_SNPRINTF
  239. # define HAVE_STRRCHR
  240. # define HAVE_STRTOD
  241. # define HAVE_SSCANF
  242. # define HAVE_STRTOL
  243. # define HAVE_STRTOUL
  244. # define HAVE_SYS_TIMEB_H
  245. # define HAVE_FTIME
  246. # define HAVE_RAND_R
  247. # define HAVE_GMTIME_R
  248. # define HAVE_LOCALTIME_R
  249. # define HAVE_WCTOMB
  250. # define HAVE_MBTOWC
  251. # elif defined(_AIX41)
  252. # define HAVE_SNPRINTF
  253. # define HAVE_STRRCHR
  254. # define HAVE_STRTOD
  255. # define HAVE_SSCANF
  256. # define HAVE_STRTOL
  257. # define HAVE_STRTOUL
  258. # define HAVE_SYS_TIMEB_H
  259. # define HAVE_WCTOMB
  260. # define HAVE_MBTOWC
  261. # elif defined(HP_UX)
  262. # define HAVE_SNPRINTF
  263. # define HAVE_STRRCHR
  264. # define HAVE_STRTOD
  265. # define HAVE_SSCANF
  266. # define HAVE_STRTOL
  267. # define HAVE_STRTOUL
  268. # define HAVE_SYS_TIMEB_H
  269. # define HAVE_FTIME
  270. # define HAVE_RAND_R
  271. # define HAVE_GMTIME_R
  272. # define HAVE_LOCALTIME_R
  273. # define HAVE_WCTOMB
  274. # define HAVE_MBTOWC
  275. # define HAVE_ISNAN
  276. # elif defined(FREEBSD) || defined(__FreeBSD__) || defined(OPENBSD)
  277. # define HAVE_POLL
  278. # define HAVE_SNPRINTF
  279. # define HAVE_STRRCHR
  280. # define HAVE_STRTOD
  281. # define HAVE_SSCANF
  282. # define HAVE_STRTOD_L
  283. # define HAVE_SSCANF_L
  284. # define HAVE_SPRINTF_L
  285. # define HAVE_STRTOL
  286. # define HAVE_STRTOUL
  287. # define HAVE_STRTOLL
  288. # define HAVE_STRTOULL
  289. # define HAVE_GETTIMEOFDAY
  290. # define HAVE_RAND_R
  291. # define HAVE_GMTIME_R
  292. # define HAVE_LOCALTIME_R
  293. # define HAVE_STRERROR_R
  294. # define HAVE_WCTOMB
  295. # define HAVE_MBTOWC
  296. # define SOAP_LONG_FORMAT "%qd"
  297. # define SOAP_ULONG_FORMAT "%qu"
  298. # define HAVE_ISNAN
  299. # define HAVE_ISINF
  300. # elif defined(__VMS)
  301. # include <ioctl.h>
  302. # define HAVE_SNPRINTF
  303. # define HAVE_STRRCHR
  304. # define HAVE_STRTOD
  305. # define HAVE_SSCANF
  306. # define HAVE_STRTOL
  307. # define HAVE_STRTOUL
  308. # define HAVE_SYS_TIMEB_H
  309. # define HAVE_FTIME
  310. # define HAVE_RAND_R
  311. # define HAVE_GMTIME_R
  312. # define HAVE_LOCALTIME_R
  313. # define HAVE_WCTOMB
  314. # define HAVE_MBTOWC
  315. # elif defined(__GLIBC__) || defined(__GNU__)
  316. # define HAVE_POLL
  317. # define HAVE_SNPRINTF
  318. # define HAVE_STRRCHR
  319. # define HAVE_STRTOD
  320. # define HAVE_SSCANF
  321. # define HAVE_STRTOD_L
  322. # define HAVE_SSCANF_L
  323. # define HAVE_SPRINTF_L
  324. # define HAVE_STRTOL
  325. # define HAVE_STRTOUL
  326. # define HAVE_STRTOLL
  327. # define HAVE_STRTOULL
  328. # define HAVE_SYS_TIMEB_H
  329. # define HAVE_FTIME
  330. # define HAVE_RAND_R
  331. # define HAVE_GMTIME_R
  332. # define HAVE_LOCALTIME_R
  333. # define HAVE_STRERROR_R
  334. # define HAVE_TIMEGM
  335. # define HAVE_WCTOMB
  336. # define HAVE_MBTOWC
  337. # define HAVE_ISNAN
  338. # define HAVE_ISINF
  339. # elif defined(TRU64)
  340. # define HAVE_SNPRINTF
  341. # define HAVE_STRRCHR
  342. # define HAVE_STRTOD
  343. # define HAVE_SSCANF
  344. # define HAVE_STRTOL
  345. # define HAVE_STRTOUL
  346. # define HAVE_GETTIMEOFDAY
  347. # define HAVE_SYS_TIMEB_H
  348. # define HAVE_RAND_R
  349. # define HAVE_GMTIME_R
  350. # define HAVE_LOCALTIME_R
  351. # define __USE_STD_IOSTREAM
  352. # define HAVE_WCTOMB
  353. # define HAVE_MBTOWC
  354. # define SOAP_LONG_FORMAT "%ld"
  355. # define SOAP_ULONG_FORMAT "%lu"
  356. # elif defined(MAC_CARBON)
  357. # define WITH_NOIO
  358. # define HAVE_SNPRINTF
  359. # define HAVE_STRRCHR
  360. # define HAVE_STRTOD
  361. # define HAVE_SSCANF
  362. # define HAVE_STRTOD_L
  363. # define HAVE_SSCANF_L
  364. # define HAVE_SPRINTF_L
  365. # define HAVE_STRTOL
  366. # define HAVE_STRTOUL
  367. # define HAVE_FTIME
  368. # define HAVE_RAND_R
  369. # define HAVE_GETHOSTBYNAME_R
  370. # define HAVE_GMTIME_R
  371. # define HAVE_LOCALTIME_R
  372. # define HAVE_STRERROR_R
  373. # define HAVE_WCTOMB
  374. # define HAVE_MBTOWC
  375. # elif defined(PALM)
  376. # define WITH_LEAN
  377. # define HAVE_STRTOD /* strtod() is defined in palmFunctions.h */
  378. # include <stdlib.h> /* Needs to be included before unix headers */
  379. # include <sys_types.h>
  380. # define IGNORE_STDIO_STUBS
  381. # include <StdIOPalm.h>
  382. # define O_NONBLOCK FNONBIO
  383. # include <sys_socket.h>
  384. # include "palmFunctions.h"
  385. # elif defined(SYMBIAN)
  386. # define WITH_LEAN
  387. # define WITH_NONAMESPACES
  388. # define HAVE_STRTOD /* use STRTOD since sscanf doesn't seem to work */
  389. # include <e32def.h>
  390. # include <sys/ioctl.h>
  391. # elif defined(VXWORKS)
  392. # ifdef _WRS_KERNEL
  393. # define _POSIX_THREADS 1
  394. # endif
  395. # define HAVE_STRRCHR
  396. # define HAVE_STRTOD
  397. # define HAVE_SSCANF
  398. # define HAVE_STRTOL
  399. # define HAVE_STRTOUL
  400. # define HAVE_GMTIME
  401. # define HAVE_LOCALTIME
  402. # define HAVE_MKTIME
  403. # elif defined(OS390)
  404. # define HAVE_SNPRINTF
  405. # define HAVE_STRRCHR
  406. # define HAVE_STRTOD
  407. # define HAVE_SSCANF
  408. # define HAVE_STRTOL
  409. # define HAVE_STRTOUL
  410. # define HAVE_SYS_TIMEB_H
  411. # define HAVE_FTIME
  412. # define HAVE_RAND_R
  413. # define HAVE_GMTIME_R
  414. # define HAVE_LOCALTIME_R
  415. # define HAVE_WCTOMB
  416. # define HAVE_MBTOWC
  417. # elif defined(AS400)
  418. # define HAVE_SNPRINTF
  419. # define HAVE_STRRCHR
  420. # define HAVE_STRTOD
  421. # define HAVE_SSCANF
  422. # define HAVE_STRTOL
  423. # define HAVE_STRTOUL
  424. # define HAVE_SYS_TIMEB_H
  425. # define HAVE_FTIME
  426. # define HAVE_RAND_R
  427. # define HAVE_GMTIME_R
  428. # define HAVE_LOCALTIME_R
  429. # define HAVE_WCTOMB
  430. # define HAVE_MBTOWC
  431. # elif defined(__QNX__) || defined(QNX)
  432. /* QNX does not have a working version of strtof */
  433. # undef HAVE_STRTOF
  434. # define HAVE_POLL
  435. # define HAVE_SNPRINTF
  436. # define HAVE_STRRCHR
  437. # define HAVE_STRTOD
  438. # define HAVE_SSCANF
  439. # define HAVE_STRTOL
  440. # define HAVE_STRTOUL
  441. # define HAVE_SYS_TIMEB_H
  442. # define HAVE_FTIME
  443. # define HAVE_RAND_R
  444. # define HAVE_GETHOSTBYNAME_R
  445. # define HAVE_GMTIME_R
  446. # define HAVE_LOCALTIME_R
  447. # define HAVE_STRERROR_R
  448. # define HAVE_WCTOMB
  449. # define HAVE_MBTOWC
  450. # elif defined(SUN_OS)
  451. # define HAVE_SNPRINTF
  452. # define HAVE_STRRCHR
  453. # define HAVE_STRTOD
  454. # define HAVE_SSCANF
  455. # define HAVE_STRTOL
  456. # define HAVE_STRTOUL
  457. # define HAVE_SYS_TIMEB_H
  458. # define HAVE_FTIME
  459. # define HAVE_RAND_R
  460. # define HAVE_GETHOSTBYNAME_R
  461. # define HAVE_GMTIME_R
  462. # define HAVE_LOCALTIME_R
  463. # else
  464. /* Default assumptions for supported functions */
  465. # define HAVE_SNPRINTF
  466. # define HAVE_STRRCHR
  467. # define HAVE_STRTOD
  468. # define HAVE_SSCANF
  469. # define HAVE_STRTOL
  470. # define HAVE_STRTOUL
  471. # define HAVE_SYS_TIMEB_H
  472. # define HAVE_FTIME
  473. # define HAVE_RAND_R
  474. # define HAVE_GETHOSTBYNAME_R
  475. # define HAVE_GMTIME_R
  476. # define HAVE_LOCALTIME_R
  477. # define HAVE_STRERROR_R
  478. # ifdef MB_LEN_MAX
  479. # define HAVE_WCTOMB
  480. # define HAVE_MBTOWC
  481. # endif
  482. # endif
  483. #endif
  484. /* gSOAP 2.7.15 and higher: always retain CDATA in literal XML, unless WITH_LEAN or WITH_NOCDATA */
  485. #ifndef WITH_LEAN
  486. # ifndef WITH_NOCDATA
  487. # ifndef WITH_CDATA
  488. # define WITH_CDATA
  489. # endif
  490. # endif
  491. #endif
  492. #ifdef WITH_LEANER
  493. # ifndef WITH_LEAN
  494. # define WITH_LEAN
  495. # endif
  496. #endif
  497. #ifdef WITH_LEAN
  498. # ifdef WITH_COOKIES
  499. # error "Cannot build WITH_LEAN code WITH_COOKIES enabled"
  500. # endif
  501. #endif
  502. /* native Win, HP-UX, and AIX compilers don't like empty structs */
  503. #if defined(WIN32) || defined(HP_UX) || defined(_AIX) || defined(AIX) || defined(VXWORKS)
  504. # define WITH_NOEMPTYSTRUCT
  505. #endif
  506. #ifdef WITH_PURE_VIRTUAL
  507. # define SOAP_PURE_VIRTUAL = 0
  508. #else
  509. # define SOAP_PURE_VIRTUAL
  510. #endif
  511. #ifdef HP_UX
  512. # undef HAVE_STRTOLL
  513. # undef HAVE_STRTOULL
  514. #endif
  515. /* older OpenVMS TCP/IP stacks cannot handle 65536 bytes */
  516. #ifdef __VMS
  517. # ifndef SOAP_BUFLEN
  518. # define SOAP_BUFLEN (65535)
  519. # endif
  520. #endif
  521. /* if we have xlocale.h we use it to avoid decimal point conversion issues */
  522. #ifdef WITH_C_LOCALE
  523. # ifdef WIN32
  524. # include <locale.h>
  525. # else
  526. # include <xlocale.h>
  527. # endif
  528. #else
  529. # undef HAVE_STRTOF_L
  530. # undef HAVE_STRTOD_L
  531. # undef HAVE_SSCANF_L
  532. # undef HAVE_SPRINTF_L
  533. #endif
  534. #ifdef TANDEM_NONSTOP /* Support for Guardian */
  535. # define SOAP_BUFLEN (32767)
  536. /*# define WITH_NOSTDLIB */ /* uncommment to remove stdlib dependences */
  537. # define WITH_NOIO /* no IO dependences, e.g. remove TCP/IP */
  538. # define int32_t int
  539. # define int64_t long long
  540. # define LONG64 long long
  541. # define ULONG64 long long
  542. # define DBL_PINFTY (1.1579208923716189e77)
  543. # define WITH_NOEMPTYSTRUCT
  544. # undef HAVE_WCTOMB
  545. # undef HAVE_MBTOWC
  546. # undef HAVE_GMTIME_R
  547. # undef HAVE_LOCALTIME_R
  548. # undef HAVE_SNPRINTF
  549. # define SOAP_BUFLEN (32767)
  550. # define SOAP_SOCKET short
  551. #pragma nolist
  552. # include <sys\param.h>
  553. # include <sys\socket.h>
  554. # include <netinet\in.h>
  555. # include <netdb.h>
  556. # include <stdio.h>
  557. # include <fcntl.h>
  558. # include <string.h>
  559. # include <stdlib.h>
  560. # include <memory.h>
  561. # include <errno.h>
  562. # include <cextdecs.h(TIME,FILE_CLOSE_,AWAITIOX,DELAY,FILEINFO,FILE_GETINFO_)>
  563. # define INET_ERROR 4294967295
  564. #pragma list
  565. #elif defined(__TANDEM) /* Support for OSS */
  566. # define int32_t int
  567. # define SOAP_BUFLEN (32767)
  568. #endif
  569. #ifndef WITH_NOSTDLIB
  570. # include <stdlib.h>
  571. # ifndef PALM
  572. # include <stdio.h>
  573. # include <string.h>
  574. # endif
  575. # include <ctype.h>
  576. # include <limits.h>
  577. #endif
  578. #ifdef WITH_NTLM
  579. # include <ntlm.h>
  580. #endif
  581. #ifdef HAVE_POLL
  582. # include <poll.h>
  583. #endif
  584. #if defined(__cplusplus) && !defined(WITH_LEAN) && !defined(WITH_COMPAT)
  585. # include <string>
  586. # include <iostream>
  587. #endif
  588. #ifdef WITH_NOHTTP
  589. # ifndef WITH_NOIO
  590. # define WITH_NOIO
  591. # undef WITH_COOKIES
  592. # endif
  593. #endif
  594. /* Suggestion when SOAP_FD_EXCEEDED error occurs:
  595. Some systems allow increasing FD_SETSIZE before including sys/types.h:
  596. #define FD_SETSIZE (2048)
  597. */
  598. #ifndef UNDER_CE
  599. # ifndef PALM
  600. # ifndef WITH_NOIO
  601. # include <errno.h>
  602. # include <sys/types.h>
  603. # endif
  604. # ifndef WITH_LEAN
  605. # ifdef HAVE_SYS_TIMEB_H
  606. # include <sys/timeb.h> /* for ftime() */
  607. # endif
  608. # include <time.h>
  609. # endif
  610. # endif
  611. #endif
  612. #ifdef OPENSERVER
  613. # include <sys/socket.h>
  614. # include <sys/stream.h>
  615. # include <sys/protosw.h>
  616. extern int h_errno;
  617. #endif
  618. #ifndef WITH_NOIO
  619. # ifndef WIN32
  620. # ifndef PALM
  621. # include <sys/socket.h>
  622. # ifdef VXWORKS
  623. # include <sockLib.h>
  624. # include <selectLib.h>
  625. # ifndef _WRS_KERNEL
  626. # include <strings.h>
  627. # endif
  628. # else
  629. # ifndef SYMBIAN
  630. # include <strings.h>
  631. # endif
  632. # endif
  633. # ifdef SUN_OS
  634. # include <sys/stream.h> /* SUN */
  635. # include <sys/socketvar.h> /* SUN < 2.8 (?) */
  636. # endif
  637. # ifdef VXWORKS
  638. # ifdef _WRS_KERNEL
  639. # include <sys/times.h>
  640. # endif
  641. # else
  642. # include <sys/time.h>
  643. # endif
  644. # include <netinet/in.h>
  645. # ifdef OS390
  646. # include <netinet/tcp_var.h>
  647. # else
  648. # include <netinet/tcp.h> /* TCP_NODELAY */
  649. # endif
  650. # include <arpa/inet.h>
  651. # endif
  652. # endif
  653. #endif
  654. #ifdef WIN32
  655. # define SOAP_WINSOCKINT int
  656. #else
  657. # define SOAP_WINSOCKINT size_t
  658. #endif
  659. #if defined(WITH_IPV6_V6ONLY) || defined(WITH_NO_IPV6_V6ONLY)
  660. # ifndef WITH_IPV6
  661. # define WITH_IPV6
  662. # endif
  663. #endif
  664. #ifdef WIN32
  665. # ifndef UNDER_CE
  666. # include <io.h>
  667. # include <fcntl.h>
  668. # endif
  669. // When you get macro redefinition errors when compiling the code below, then:
  670. // a) try arrange your includes so <windows.h> is included after "stdsoap2.h"
  671. // b) or define _WINSOCKAPI_ first:
  672. // #define _WINSOCKAPI_ // stops windows.h including winsock.h
  673. // #include <windows.h>
  674. // #include "stdsoap2.h"
  675. // c) or compile with the -DWIN32_LEAN_AND_MEAN switch
  676. # include <winsock2.h> // Visual Studio 2005 users: install Platform SDK (R2)
  677. # include <ws2tcpip.h>
  678. // # define _WSPIAPI_COUNTOF // DEV NOTE: enble to fix problems with VC6
  679. // # include <wspiapi.h>
  680. # include <ws2spi.h> // DEV NOTE: replaces older wspiapi.h above
  681. # ifdef WITH_IPV6
  682. # define SOAP_GAI_STRERROR gai_strerrorA
  683. # endif
  684. #else
  685. # ifdef VXWORKS
  686. # include <hostLib.h>
  687. # include <ioctl.h>
  688. # include <ioLib.h>
  689. # endif
  690. # ifndef WITH_NOIO
  691. # ifndef PALM
  692. # include <netdb.h>
  693. # include <netinet/in.h>
  694. # include <unistd.h>
  695. # include <fcntl.h>
  696. # ifdef _AIX41
  697. # include <sys/select.h>
  698. # endif
  699. # endif
  700. # endif
  701. #endif
  702. #ifdef WITH_FASTCGI
  703. # include <fcgi_stdio.h>
  704. #endif
  705. #ifdef WITH_OPENSSL
  706. # ifdef __VMS
  707. # pragma names save
  708. # pragma names uppercase
  709. # endif
  710. # undef WITH_GNUTLS
  711. # define OPENSSL_NO_KRB5
  712. # include <openssl/bio.h>
  713. # include <openssl/err.h>
  714. # include <openssl/rand.h>
  715. # include <openssl/ssl.h>
  716. # include <openssl/x509v3.h>
  717. # ifndef ALLOW_OLD_VERSIONS
  718. # if (OPENSSL_VERSION_NUMBER < 0x00905100L)
  719. # error "Must use OpenSSL 0.9.6 or later"
  720. # endif
  721. # endif
  722. # ifdef __VMS
  723. # pragma names restore
  724. # endif
  725. #endif
  726. #ifdef WITH_GNUTLS
  727. # include <gnutls/gnutls.h>
  728. # include <gnutls/x509.h>
  729. # include <gcrypt.h>
  730. # ifndef HAVE_PTHREAD_H
  731. # ifdef _POSIX_THREADS
  732. # define HAVE_PTHREAD_H /* make GNUTLS thread safe */
  733. # endif
  734. # endif
  735. #endif
  736. #ifdef WITH_GZIP
  737. # ifndef WITH_ZLIB
  738. # define WITH_ZLIB
  739. # endif
  740. #endif
  741. #ifdef WITH_CASEINSENSITIVETAGS
  742. # define SOAP_STRCMP soap_tag_cmp /* case insensitve XML element/attribute names */
  743. #else
  744. # define SOAP_STRCMP strcmp /* case sensitive XML element/attribute names */
  745. #endif
  746. #ifdef WITH_ZLIB
  747. # include <zlib.h>
  748. #endif
  749. #ifndef WITH_NOSTDLIB
  750. # ifndef PALM
  751. # include <math.h> /* for isnan() */
  752. # endif
  753. #endif
  754. /* #define DEBUG */ /* Uncomment to debug sending (in file SENT.log) receiving (in file RECV.log) and internal operations (in file TEST.log) */
  755. /* #define DEBUG_STAMP */ /* Uncomment to debug sending (in file SENT.log) receiving (in file RECV.log) and time-stamped operations (in file TEST.log) */
  756. #ifdef __cplusplus
  757. extern "C" {
  758. #endif
  759. /* Portability: define SOAP_SOCKLEN_T */
  760. #if defined(_AIX) || defined(AIX)
  761. # if defined(_AIX43)
  762. # define SOAP_SOCKLEN_T socklen_t
  763. # else
  764. # define SOAP_SOCKLEN_T int
  765. # endif
  766. #elif defined(SOCKLEN_T)
  767. # define SOAP_SOCKLEN_T SOCKLEN_T
  768. #elif defined(__socklen_t_defined) || defined(_SOCKLEN_T) || defined(CYGWIN) || defined(FREEBSD) || defined(__FreeBSD__) || defined(OPENBSD) || defined(__QNX__) || defined(QNX) || defined(OS390) || defined(__ANDROID__)
  769. # define SOAP_SOCKLEN_T socklen_t
  770. #elif defined(IRIX) || defined(WIN32) || defined(__APPLE__) || defined(SUN_OS) || defined(OPENSERVER) || defined(TRU64) || defined(VXWORKS) || defined(HP_UX)
  771. # define SOAP_SOCKLEN_T int
  772. #else
  773. # define SOAP_SOCKLEN_T size_t
  774. #endif
  775. #ifndef SOAP_SOCKET
  776. # ifdef WIN32
  777. # define SOAP_SOCKET SOCKET
  778. # define soap_closesocket(n) closesocket(n)
  779. # else
  780. # define SOAP_SOCKET int
  781. # define soap_closesocket(n) close(n)
  782. # endif
  783. #endif
  784. #define SOAP_INVALID_SOCKET ((SOAP_SOCKET)-1)
  785. #define soap_valid_socket(n) ((n) != SOAP_INVALID_SOCKET)
  786. #define SOAP_SHUT_WR 1
  787. #define SOAP_SHUT_RDWR 2
  788. #ifndef SOAP_GAI_STRERROR
  789. # define SOAP_GAI_STRERROR gai_strerror
  790. #endif
  791. #ifndef FD_SETSIZE
  792. # define FD_SETSIZE (1024)
  793. #endif
  794. #ifdef WITH_LEAN
  795. # define SOAP_CHK_EOF SOAP_EOF
  796. #else
  797. # define SOAP_CHK_EOF (soap->error ? soap->error : SOAP_EOF)
  798. #endif
  799. #ifdef __cplusplus
  800. # ifndef __STDC_FORMAT_MACROS
  801. # define __STDC_FORMAT_MACROS
  802. # endif
  803. #endif
  804. #if defined(SYMBIAN)
  805. # define LONG64 long
  806. # define ULONG64 unsigned LONG64
  807. #elif !defined(WIN32) || defined(CYGWIN) || defined(__GLIBC__) || defined(__GNU__)
  808. # ifndef LONG64
  809. # if defined(HAVE_INTTYPES_H)
  810. # ifdef HAVE_STDINT_H
  811. # include <stdint.h>
  812. # endif
  813. # include <inttypes.h>
  814. # define LONG64 int64_t
  815. # define ULONG64 uint64_t
  816. # elif defined(HAVE_SYS_INTTYPES_H)
  817. # include <sys/inttypes.h>
  818. # define LONG64 int64_t
  819. # define ULONG64 uint64_t
  820. # elif defined(HAVE_STDINT_H)
  821. # include <stdint.h>
  822. # define LONG64 int64_t
  823. # define ULONG64 uint64_t
  824. # elif defined(__GLIBC__)
  825. # include <bits/wordsize.h>
  826. # if (__WORDSIZE == 64)
  827. # define LONG64 int64_t
  828. # define ULONG64 uint64_t
  829. # ifndef SOAP_LONG_FORMAT
  830. # define SOAP_LONG_FORMAT "%ld"
  831. # endif
  832. # ifndef SOAP_ULONG_FORMAT
  833. # define SOAP_ULONG_FORMAT "%lu"
  834. # endif
  835. # else
  836. # define LONG64 long long
  837. # define ULONG64 unsigned LONG64
  838. # endif
  839. # else
  840. # define LONG64 long long
  841. # define ULONG64 unsigned LONG64
  842. # endif
  843. # endif
  844. #elif defined(UNDER_CE)
  845. # define LONG64 __int64
  846. # define ULONG64 unsigned LONG64
  847. #elif defined(__BORLANDC__)
  848. # define LONG64 __int64
  849. # define ULONG64 unsigned LONG64
  850. #endif
  851. #ifdef PRId64
  852. # ifndef SOAP_LONG_FORMAT
  853. # define SOAP_LONG_FORMAT "%" PRId64
  854. # endif
  855. #endif
  856. #ifdef PRIu64
  857. # ifndef SOAP_ULONG_FORMAT
  858. # define SOAP_ULONG_FORMAT "%" PRIu64
  859. # endif
  860. #endif
  861. #ifndef SOAP_LONG_FORMAT
  862. # define SOAP_LONG_FORMAT "%lld" /* printf format for 64 bit ints */
  863. #endif
  864. #ifndef SOAP_ULONG_FORMAT
  865. # define SOAP_ULONG_FORMAT "%llu" /* printf format for unsigned 64 bit ints */
  866. #endif
  867. #if defined(WIN32) && !defined(CYGWIN)
  868. # define soap_int32 __int32
  869. #elif defined(SYMBIAN)
  870. # define soap_int32 long
  871. #elif defined(PALM)
  872. # define soap_int32 Int32
  873. #elif defined(_AIX) || defined(AIX)
  874. # if defined(_AIX43)
  875. # define soap_int32 int32_t
  876. # else
  877. # define soap_int32 signed int
  878. # endif
  879. #else
  880. # define soap_int32 int32_t
  881. #endif
  882. #ifdef WIN32
  883. # define SOAP_ERANGE ERANGE
  884. # define SOAP_EINTR WSAEINTR
  885. # define SOAP_EAGAIN WSAEWOULDBLOCK
  886. # define SOAP_EWOULDBLOCK WSAEWOULDBLOCK
  887. # define SOAP_EINPROGRESS WSAEINPROGRESS
  888. # define SOAP_EADDRINUSE WSAEADDRINUSE
  889. #else
  890. # define SOAP_ERANGE ERANGE
  891. # define SOAP_EINTR EINTR
  892. # define SOAP_EAGAIN EAGAIN
  893. # define SOAP_EADDRINUSE EADDRINUSE
  894. # ifdef SYMBIAN
  895. # define SOAP_EWOULDBLOCK 9898
  896. # define SOAP_EINPROGRESS 9899
  897. # else
  898. # define SOAP_EWOULDBLOCK EWOULDBLOCK
  899. # define SOAP_EINPROGRESS EINPROGRESS
  900. # endif
  901. #endif
  902. #ifdef WIN32
  903. # ifdef UNDER_CE
  904. # define soap_errno GetLastError()
  905. # define soap_socket_errno(s) GetLastError()
  906. # define soap_reset_errno SetLastError(0)
  907. # else
  908. # define soap_errno GetLastError()
  909. # define soap_socket_errno(s) WSAGetLastError()
  910. # define soap_reset_errno SetLastError(0)
  911. # endif
  912. #else
  913. # ifndef WITH_NOIO
  914. # define soap_errno errno
  915. # define soap_socket_errno(s) errno
  916. # define soap_reset_errno (errno = 0)
  917. # else
  918. # define soap_errno 0
  919. # define soap_socket_errno(s) 0
  920. # define soap_reset_errno
  921. # endif
  922. #endif
  923. #ifndef SOAP_BUFLEN
  924. # if !defined(WITH_LEAN)
  925. # define SOAP_BUFLEN (65536) /* buffer length for socket packets, also used by gethostbyname_r and UDP messages, so don't make this too small */
  926. # else
  927. # define SOAP_BUFLEN (2048) /* lean size */
  928. # endif
  929. #endif
  930. #ifndef SOAP_LABLEN
  931. # define SOAP_LABLEN (256) /* initial look-aside buffer length */
  932. #endif
  933. #ifndef SOAP_PTRBLK
  934. # define SOAP_PTRBLK (32) /* block allocation for pointer hash table chains */
  935. #endif
  936. #ifndef SOAP_PTRHASH
  937. # ifndef WITH_LEAN
  938. # define SOAP_PTRHASH (4096) /* size of pointer analysis hash table (must be power of 2) */
  939. # else
  940. # define SOAP_PTRHASH (32)
  941. # endif
  942. #endif
  943. #ifndef SOAP_IDHASH
  944. # ifndef WITH_LEAN
  945. # define SOAP_IDHASH (1999) /* prime size of hash table for parsed id/ref */
  946. # else
  947. # define SOAP_IDHASH (19) /* 19, 199 */
  948. # endif
  949. #endif
  950. #ifndef SOAP_BLKLEN
  951. # ifndef WITH_LEAN
  952. # define SOAP_BLKLEN (256) /* to collect long strings and XML attributes */
  953. # else
  954. # define SOAP_BLKLEN (32)
  955. # endif
  956. #endif
  957. #ifndef SOAP_TAGLEN
  958. # ifndef WITH_LEAN
  959. # define SOAP_TAGLEN (1024) /* maximum length of XML element tag/attribute name or host/path name + 1 */
  960. # else
  961. # define SOAP_TAGLEN (128)
  962. # endif
  963. #endif
  964. #ifndef SOAP_HDRLEN
  965. # ifndef WITH_LEAN
  966. # define SOAP_HDRLEN (8192) /* maximum length of HTTP header line (must be >4096 to read cookies) */
  967. # else
  968. # define SOAP_HDRLEN (1024)
  969. # endif
  970. #endif
  971. #ifndef SOAP_MAXDIMS
  972. # ifndef WITH_LEAN
  973. # define SOAP_MAXDIMS (16) /* maximum array dimensions (array nestings) must be less than 64 to protect soap->tmpbuf */
  974. # else
  975. # define SOAP_MAXDIMS (4)
  976. # endif
  977. #endif
  978. #ifndef SOAP_MAXLOGS
  979. # define SOAP_MAXLOGS (3) /* max number of debug logs per struct soap environment */
  980. # define SOAP_INDEX_RECV (0)
  981. # define SOAP_INDEX_SENT (1)
  982. # define SOAP_INDEX_TEST (2)
  983. #endif
  984. /* Max number of EINTR while poll/select on a socket */
  985. /* Each EINTR can lengthen the I/O blocking time by at most one second */
  986. #ifndef SOAP_MAXEINTR
  987. # define SOAP_MAXEINTR (10)
  988. #endif
  989. /* Max iterations in soap_serve() to keep server connection alive */
  990. #ifndef SOAP_MAXKEEPALIVE
  991. # define SOAP_MAXKEEPALIVE (100)
  992. #endif
  993. /* Trusted max size of inbound SOAP array for compound array allocation.
  994. Increase if necessary to allow larger arrays.
  995. */
  996. #ifndef SOAP_MAXARRAYSIZE
  997. # define SOAP_MAXARRAYSIZE (1000000)
  998. #endif
  999. /* Trusted max size of inbound DIME data.
  1000. Increase if necessary to allow larger attachments, or decrease when server
  1001. resources are limited.
  1002. */
  1003. #ifndef SOAP_MAXDIMESIZE
  1004. # define SOAP_MAXDIMESIZE (8388608) /* 8 MB */
  1005. #endif
  1006. #ifdef VXWORKS
  1007. # ifdef WMW_RPM_IO
  1008. # include "httpLib.h"
  1009. # endif
  1010. # ifdef __INCmathh
  1011. # include <private/mathP.h>
  1012. # ifndef HAVE_ISNAN
  1013. # define HAVE_ISNAN
  1014. # endif
  1015. # ifndef soap_isnan
  1016. # define soap_isnan(num) isNan(num)
  1017. # endif
  1018. # endif
  1019. # ifdef WM_SECURE_KEY_STORAGE
  1020. # include <ipcom_key_db.h>
  1021. # endif
  1022. #endif
  1023. #ifdef WIN32
  1024. # include <float.h>
  1025. # ifndef HAVE_ISNAN
  1026. # define HAVE_ISNAN
  1027. # endif
  1028. # define soap_isnan(n) _isnan(n)
  1029. # ifndef HAVE_ISINF
  1030. # define HAVE_ISINF
  1031. # endif
  1032. # define soap_isinf(n) (!_finite(n))
  1033. #endif
  1034. #ifdef SUN_OS
  1035. # define HAVE_ISNAN
  1036. #endif
  1037. #ifdef __APPLE__
  1038. # ifdef __cplusplus
  1039. # ifndef isnan
  1040. extern "C" int isnan(double);
  1041. extern "C" int isinf(double);
  1042. # endif
  1043. # endif
  1044. # ifndef HAVE_ISNAN
  1045. # define HAVE_ISNAN
  1046. # endif
  1047. # ifndef HAVE_ISINF
  1048. # define HAVE_ISINF
  1049. # endif
  1050. #endif
  1051. #if !defined(HAVE_ISNAN) && (defined(_MATH_H) || defined(_MATH_INCLUDED))
  1052. # define HAVE_ISNAN
  1053. #endif
  1054. union soap_double_nan {struct {unsigned int n1, n2;} iv; double dv; float fv;};
  1055. extern const union soap_double_nan soap_double_nan;
  1056. extern const char soap_base64o[], soap_base64i[];
  1057. #ifdef VXWORKS
  1058. # ifndef FLT_MAX
  1059. # define FLT_MAX _ARCH_FLT_MAX
  1060. # endif
  1061. # ifndef DBL_MAX
  1062. # define DBL_MAX _ARCH_DBL_MAX
  1063. # endif
  1064. #endif
  1065. #ifndef FLT_NAN
  1066. # define FLT_NAN (soap_double_nan.fv)
  1067. #endif
  1068. #ifndef FLT_PINFTY
  1069. # if defined(FLT_MAX)
  1070. # define FLT_PINFTY FLT_MAX
  1071. # elif defined(HUGE_VALF)
  1072. # define FLT_PINFTY (float)HUGE_VALF
  1073. # elif defined(HUGE_VAL)
  1074. # define FLT_PINFTY (float)HUGE_VAL
  1075. # elif defined(FLOAT_MAX)
  1076. # define FLT_PINFTY FLOAT_MAX
  1077. # else
  1078. # define FLT_PINFTY (3.40282347e+38F)
  1079. # endif
  1080. #endif
  1081. #ifndef FLT_NINFTY
  1082. # define FLT_NINFTY (-FLT_PINFTY)
  1083. #endif
  1084. #ifndef DBL_NAN
  1085. # define DBL_NAN (soap_double_nan.dv)
  1086. #endif
  1087. #ifndef DBL_PINFTY
  1088. # if defined(DBL_MAX)
  1089. # define DBL_PINFTY DBL_MAX
  1090. # elif defined(HUGE_VALF)
  1091. # define DBL_PINFTY (double)HUGE_VALF
  1092. # elif defined(HUGE_VAL)
  1093. # define DBL_PINFTY (double)HUGE_VAL
  1094. # elif defined(DOUBLE_MAX)
  1095. # define DBL_PINFTY DOUBLE_MAX
  1096. # else
  1097. # define DBL_PINFTY (1.7976931348623157e+308)
  1098. # endif
  1099. #endif
  1100. #ifndef DBL_NINFTY
  1101. # define DBL_NINFTY (-DBL_PINFTY)
  1102. #endif
  1103. #ifndef soap_isnan
  1104. # ifdef HAVE_ISNAN
  1105. # define soap_isnan(n) isnan(n)
  1106. # else
  1107. # define soap_isnan(n) ((n) != (n))
  1108. # endif
  1109. #endif
  1110. #ifndef soap_isinf
  1111. # ifdef HAVE_ISINF
  1112. # define soap_isinf(n) isinf(n)
  1113. # else
  1114. # define soap_isinf(n) (!soap_isnan(n) && soap_isnan((n) - (n)))
  1115. # endif
  1116. #endif
  1117. #define soap_ispinfd(n) ((n) > 0 && soap_isinf(n))
  1118. #define soap_ispinff(n) ((n) > 0 && soap_isinf(n))
  1119. #define soap_isninfd(n) ((n) < 0 && soap_isinf(n))
  1120. #define soap_isninff(n) ((n) < 0 && soap_isinf(n))
  1121. #ifdef HAVE_SNPRINTF
  1122. # ifdef WIN32
  1123. # define soap_snprintf(buf, len, ...) (_snprintf((buf), (len), __VA_ARGS__), (buf)[(len)-1] = '\0')
  1124. # else
  1125. # define soap_snprintf snprintf
  1126. # endif
  1127. #endif
  1128. /* gSOAP status/error codes */
  1129. typedef soap_int32 soap_status;
  1130. #define SOAP_EOF EOF
  1131. #define SOAP_ERR EOF
  1132. #define SOAP_OK 0
  1133. #define SOAP_CLI_FAULT 1
  1134. #define SOAP_SVR_FAULT 2
  1135. #define SOAP_TAG_MISMATCH 3
  1136. #define SOAP_TYPE 4
  1137. #define SOAP_SYNTAX_ERROR 5
  1138. #define SOAP_NO_TAG 6
  1139. #define SOAP_IOB 7
  1140. #define SOAP_MUSTUNDERSTAND 8
  1141. #define SOAP_NAMESPACE 9
  1142. #define SOAP_USER_ERROR 10
  1143. #define SOAP_FATAL_ERROR 11
  1144. #define SOAP_FAULT 12
  1145. #define SOAP_NO_METHOD 13
  1146. #define SOAP_NO_DATA 14
  1147. #define SOAP_GET_METHOD 15
  1148. #define SOAP_PUT_METHOD 16
  1149. #define SOAP_DEL_METHOD 17 /* deprecated */
  1150. #define SOAP_HEAD_METHOD 18 /* deprecated */
  1151. #define SOAP_HTTP_METHOD 19
  1152. #define SOAP_EOM 20
  1153. #define SOAP_MOE 21
  1154. #define SOAP_HDR 22
  1155. #define SOAP_NULL 23
  1156. #define SOAP_DUPLICATE_ID 24
  1157. #define SOAP_MISSING_ID 25
  1158. #define SOAP_HREF 26
  1159. #define SOAP_UDP_ERROR 27
  1160. #define SOAP_TCP_ERROR 28
  1161. #define SOAP_HTTP_ERROR 29
  1162. #define SOAP_SSL_ERROR 30
  1163. #define SOAP_ZLIB_ERROR 31
  1164. #define SOAP_DIME_ERROR 32
  1165. #define SOAP_DIME_HREF 33
  1166. #define SOAP_DIME_MISMATCH 34
  1167. #define SOAP_DIME_END 35
  1168. #define SOAP_MIME_ERROR 36
  1169. #define SOAP_MIME_HREF 37
  1170. #define SOAP_MIME_END 38
  1171. #define SOAP_VERSIONMISMATCH 39
  1172. #define SOAP_PLUGIN_ERROR 40
  1173. #define SOAP_DATAENCODINGUNKNOWN 41
  1174. #define SOAP_REQUIRED 42
  1175. #define SOAP_PROHIBITED 43
  1176. #define SOAP_OCCURS 44
  1177. #define SOAP_LENGTH 45
  1178. #define SOAP_FD_EXCEEDED 46
  1179. #define SOAP_UTF_ERROR 47
  1180. #define SOAP_NTLM_ERROR 48
  1181. #define soap_xml_error_check(e) ((e) == SOAP_TAG_MISMATCH || (e) == SOAP_NO_TAG || (e) == SOAP_SYNTAX_ERROR || (e) == SOAP_NAMESPACE || (e) == SOAP_DUPLICATE_ID || (e) == SOAP_MISSING_ID || (e) == SOAP_REQUIRED || (e) == SOAP_PROHIBITED || (e) == SOAP_OCCURS || (e) == SOAP_LENGTH || (e) == SOAP_NULL || (e) == SOAP_HREF)
  1182. #define soap_soap_error_check(e) ((e) == SOAP_CLI_FAULT || (e) == SOAP_SVR_FAULT || (e) == SOAP_VERSIONMISMATCH || (e) == SOAP_MUSTUNDERSTAND || (e) == SOAP_FAULT || (e) == SOAP_NO_METHOD)
  1183. #define soap_tcp_error_check(e) ((e) == SOAP_EOF || (e) == SOAP_TCP_ERROR)
  1184. #define soap_ssl_error_check(e) ((e) == SOAP_SSL_ERROR)
  1185. #define soap_zlib_error_check(e) ((e) == SOAP_ZLIB_ERROR)
  1186. #define soap_http_error_check(e) ((e) == SOAP_HTTP_ERROR || (e) == SOAP_NO_DATA || ((e) >= SOAP_GET_METHOD && (e) <= SOAP_HTTP_METHOD) || ((e) >= 100 && (e) < 600))
  1187. /* gSOAP HTTP response status codes 100 to 599 are reserved */
  1188. /* Codes 600 to 999 are user definable */
  1189. /* Exceptional gSOAP HTTP server response status codes >= 1000 */
  1190. #define SOAP_STOP 1000 /* No HTTP response */
  1191. #define SOAP_FORM 1001 /* Request (form) data is present, no HTTP response */
  1192. #define SOAP_HTML 1002 /* Custom HTML response */
  1193. #define SOAP_FILE 1003 /* Custom file-based response */
  1194. /* gSOAP HTTP method codes (client) */
  1195. #define SOAP_POST 2000 /* POST request */
  1196. #define SOAP_POST_FILE 2001 /* Custom file-based POST request */
  1197. #define SOAP_GET 2002 /* GET request */
  1198. #define SOAP_PUT 2003 /* PUT request */
  1199. #define SOAP_DEL 2004 /* DELETE request */
  1200. #define SOAP_CONNECT 2005 /* CONNECT request */
  1201. /* gSOAP DIME */
  1202. #define SOAP_DIME_CF 0x01
  1203. #define SOAP_DIME_ME 0x02
  1204. #define SOAP_DIME_MB 0x04
  1205. #define SOAP_DIME_VERSION 0x08 /* DIME version 1 */
  1206. #define SOAP_DIME_MEDIA 0x10
  1207. #define SOAP_DIME_ABSURI 0x20
  1208. /* gSOAP ZLIB */
  1209. #define SOAP_ZLIB_NONE 0x00
  1210. #define SOAP_ZLIB_DEFLATE 0x01
  1211. #define SOAP_ZLIB_INFLATE 0x02
  1212. #define SOAP_ZLIB_GZIP 0x02
  1213. /* gSOAP transport, connection, and content encoding modes */
  1214. typedef soap_int32 soap_mode;
  1215. #define SOAP_IO 0x00000003 /* IO mask */
  1216. #define SOAP_IO_FLUSH 0x00000000 /* flush output immediately, no buffering */
  1217. #define SOAP_IO_BUFFER 0x00000001 /* buffer output in packets of size SOAP_BUFLEN */
  1218. #define SOAP_IO_STORE 0x00000002 /* store entire output to determine length for transport */
  1219. #define SOAP_IO_CHUNK 0x00000003 /* use HTTP chunked transfer AND buffer packets */
  1220. #define SOAP_IO_UDP 0x00000004 /* TCP or UDP */
  1221. #define SOAP_IO_LENGTH 0x00000008 /* calc message length (internal) */
  1222. #define SOAP_IO_KEEPALIVE 0x00000010 /* keep connection alive */
  1223. #define SOAP_ENC 0x00000FFF /* IO and ENC mask */
  1224. #define SOAP_ENC_LATIN 0x00000020 /* in: accept iso-8859-1 */
  1225. #define SOAP_ENC_XML 0x00000040 /* out: plain XML encoding, no HTTP header */
  1226. #define SOAP_ENC_DIME 0x00000080
  1227. #define SOAP_ENC_MIME 0x00000100
  1228. #define SOAP_ENC_MTOM 0x00000200
  1229. #define SOAP_ENC_ZLIB 0x00000400
  1230. #define SOAP_ENC_SSL 0x00000800
  1231. #define SOAP_XML_STRICT 0x00001000 /* in: strict validation */
  1232. #define SOAP_XML_INDENT 0x00002000 /* out: emit indented XML */
  1233. #define SOAP_XML_IGNORENS 0x00004000 /* in: ignore namespaces */
  1234. #define SOAP_XML_DEFAULTNS 0x00008000 /* out: emit xmlns="..." */
  1235. #define SOAP_XML_CANONICAL 0x00010000 /* out: excC14N canonical XML */
  1236. #define SOAP_XML_TREE 0x00020000 /* in/out: XML tree (no id/ref) */
  1237. #define SOAP_XML_NIL 0x00040000 /* out: NULLs as xsi:nil */
  1238. #define SOAP_XML_NOTYPE 0x00080000 /* out: do not add xsi:type */
  1239. #define SOAP_DOM_TREE 0x00100000 /* see DOM manual */
  1240. #define SOAP_DOM_NODE 0x00200000
  1241. #define SOAP_DOM_ASIS 0x00400000
  1242. #define SOAP_C_NOIOB 0x01000000 /* don't fault on array index out of bounds (just ignore) */
  1243. #define SOAP_C_UTFSTRING 0x02000000 /* (de)serialize strings with UTF8 content */
  1244. #define SOAP_C_MBSTRING 0x04000000 /* (de)serialize strings with multi-byte content */
  1245. #define SOAP_C_NILSTRING 0x08000000 /* serialize empty strings as nil (omitted) */
  1246. #define SOAP_XML_DOM 0x10000000 /* enable internal DOM */
  1247. #define SOAP_XML_GRAPH 0x20000000 /* force id-ref XML graph */
  1248. #define SOAP_MIME_POSTCHECK 0x40000000 /* MIME flag (internal) */
  1249. #define SOAP_SEC_WSUID 0x80000000 /* Add Body wsu:Id */
  1250. /* WITH_XMLNS backward compatibility: always use XML default namespaces */
  1251. #ifdef WITH_XMLNS
  1252. # define SOAP_IO_DEFAULT (SOAP_IO_FLUSH | SOAP_XML_DEFAULTNS)
  1253. #else
  1254. # define SOAP_IO_DEFAULT SOAP_IO_FLUSH
  1255. #endif
  1256. /* SSL client/server authentication settings */
  1257. #define SOAP_SSL_NO_AUTHENTICATION 0x00 /* for testing purposes */
  1258. #define SOAP_SSL_REQUIRE_SERVER_AUTHENTICATION 0x01 /* client requires server to authenticate */
  1259. #define SOAP_SSL_REQUIRE_CLIENT_AUTHENTICATION 0x02 /* server requires client to authenticate */
  1260. #define SOAP_SSL_SKIP_HOST_CHECK 0x04 /* client does not check the common name of the host in certificate */
  1261. #define SOAP_SSL_ALLOW_EXPIRED_CERTIFICATE 0x08 /* client does not check the expiration date of the host certificate */
  1262. #define SOAP_SSL_NO_DEFAULT_CA_PATH 0x10 /* don't use default_verify_paths */
  1263. #define SOAP_SSL_RSA 0x20 /* use RSA */
  1264. #define SOAP_SSLv3 0x40 /* SSL v3 only */
  1265. #define SOAP_TLSv1 0x80 /* TLS v1 only */
  1266. #define SOAP_SSLv3_TLSv1 0x00 /* SSL v3 and TLS v1 support by default (no SSL v1/v2) */
  1267. #define SOAP_SSL_CLIENT 0x100 /* client context */
  1268. #define SOAP_SSL_DEFAULT (SOAP_SSL_REQUIRE_SERVER_AUTHENTICATION | SOAP_SSLv3_TLSv1)
  1269. /* state */
  1270. #define SOAP_NONE 0
  1271. #define SOAP_INIT 1
  1272. #define SOAP_COPY 2
  1273. #define soap_check_state(soap) (!(soap) || ((soap)->state != SOAP_INIT && (soap)->state != SOAP_COPY))
  1274. /* parts */
  1275. #define SOAP_BEGIN 0
  1276. #define SOAP_IN_ENVELOPE 2
  1277. #define SOAP_IN_HEADER 3
  1278. #define SOAP_END_HEADER 4
  1279. #define SOAP_NO_BODY 5
  1280. #define SOAP_IN_BODY 6
  1281. #define SOAP_END_BODY 7
  1282. #define SOAP_END_ENVELOPE 8
  1283. #define SOAP_END 9
  1284. /* events */
  1285. #define SOAP_SEC_BEGIN 1
  1286. #define SOAP_SEC_SIGN 2
  1287. #define SOAP_SEC_DECRYPT 3
  1288. /* DEBUG macros */
  1289. #ifndef WITH_LEAN
  1290. # ifdef DEBUG_STAMP
  1291. # ifndef DEBUG
  1292. # define DEBUG
  1293. # endif
  1294. # endif
  1295. # ifdef DEBUG
  1296. # ifndef SOAP_DEBUG
  1297. # define SOAP_DEBUG
  1298. # endif
  1299. # ifndef SOAP_MEM_DEBUG
  1300. # define SOAP_MEM_DEBUG
  1301. # endif
  1302. # endif
  1303. #endif
  1304. #ifdef SOAP_MEM_DEBUG
  1305. # ifndef SOAP_MALLOC
  1306. # define SOAP_MALLOC(soap, size) soap_track_malloc(soap, __FILE__, __LINE__, size)
  1307. # endif
  1308. # ifndef SOAP_FREE
  1309. # define SOAP_FREE(soap, ptr) soap_track_free(soap, __FILE__, __LINE__, ptr)
  1310. # endif
  1311. #endif
  1312. #ifndef SOAP_MALLOC /* use libc malloc */
  1313. # define SOAP_MALLOC(soap, size) malloc(size)
  1314. #endif
  1315. #ifndef SOAP_FREE /* use libc free */
  1316. # define SOAP_FREE(soap, ptr) free(ptr)
  1317. #endif
  1318. #if defined(__GNUC__) && (__GNUC__ <= 2)
  1319. # define SOAP_NOTHROW
  1320. #elif !defined(WITH_LEAN) && !defined(WITH_COMPAT) && !defined(SOAP_NOTHROW)
  1321. # define SOAP_NOTHROW (std::nothrow)
  1322. #else
  1323. # define SOAP_NOTHROW
  1324. #endif
  1325. #if (defined(__GNUC__) && (__GNUC__ <= 2) && !defined(__BORLANDC__)) || defined(__clang__) || defined(_AIX) || defined(AIX)
  1326. /* old form w/o parenthesis */
  1327. # ifndef SOAP_NEW
  1328. # define SOAP_NEW(type) new SOAP_NOTHROW type
  1329. # endif
  1330. # ifndef SOAP_NEW_ARRAY
  1331. # define SOAP_NEW_ARRAY(type, n) new SOAP_NOTHROW type[n]
  1332. # endif
  1333. # ifndef SOAP_PLACEMENT_NEW
  1334. # define SOAP_PLACEMENT_NEW(buf, type) new (buf) type
  1335. # endif
  1336. #else
  1337. /* new form with parenthesis */
  1338. # ifndef SOAP_NEW
  1339. # define SOAP_NEW(type) new SOAP_NOTHROW (type)
  1340. # endif
  1341. # ifndef SOAP_NEW_ARRAY
  1342. # define SOAP_NEW_ARRAY(type, n) new SOAP_NOTHROW type[n]
  1343. # endif
  1344. # ifndef SOAP_PLACEMENT_NEW
  1345. # define SOAP_PLACEMENT_NEW(buf, type) new (buf) (type)
  1346. # endif
  1347. #endif
  1348. #ifndef SOAP_NEW_COPY /* use C++ new operator for ::copy() */
  1349. # define SOAP_NEW_COPY(clas) new SOAP_NOTHROW clas
  1350. #endif
  1351. #ifndef SOAP_DELETE /* use C++ delete operator */
  1352. # define SOAP_DELETE(obj) delete obj
  1353. #endif
  1354. #ifndef SOAP_DELETE_ARRAY /* use C++ delete[] operator */
  1355. # define SOAP_DELETE_ARRAY(obj) delete[] obj
  1356. #endif
  1357. #ifdef SOAP_DEBUG
  1358. # ifndef SOAP_MESSAGE
  1359. # define SOAP_MESSAGE fprintf
  1360. # endif
  1361. # ifndef DBGLOG
  1362. # ifdef DEBUG_STAMP
  1363. # ifdef WIN32
  1364. # define DBGLOG(DBGFILE, CMD) \
  1365. { if (soap)\
  1366. { if (!soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1367. soap_open_logfile((struct soap*)soap, SOAP_INDEX_##DBGFILE);\
  1368. if (soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1369. { FILE *fdebug = soap->fdebug[SOAP_INDEX_##DBGFILE];\
  1370. SYSTEMTIME _localTime;\
  1371. ::GetLocalTime(&_localTime); \
  1372. fprintf(fdebug, "%02d%02d%02d %02d:%02d:%02d.%03d|", _localTime.wYear%100, _localTime.wMonth, _localTime.wDay, _localTime.wHour, _localTime.wMinute, _localTime.wSecond, _localTime.wMilliseconds);\
  1373. CMD;\
  1374. fflush(fdebug);\
  1375. }\
  1376. }\
  1377. }
  1378. # else
  1379. # define DBGLOG(DBGFILE, CMD) \
  1380. { if (soap)\
  1381. { if (!soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1382. soap_open_logfile((struct soap*)soap, SOAP_INDEX_##DBGFILE);\
  1383. if (soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1384. { FILE *fdebug = soap->fdebug[SOAP_INDEX_##DBGFILE];\
  1385. struct timeval _tv;\
  1386. struct tm _tm;\
  1387. gettimeofday(&_tv, NULL);\
  1388. localtime_r(&_tv.tv_sec, &_tm);\
  1389. fprintf(fdebug, "%02d%02d%02d %02d:%02d:%02d.%06d|", _tm.tm_year%100, _tm.tm_mon+1, _tm.tm_mday, _tm.tm_hour, _tm.tm_min, _tm.tm_sec, _tv.tv_usec);\
  1390. CMD;\
  1391. fflush(fdebug);\
  1392. }\
  1393. }\
  1394. }
  1395. # endif
  1396. # else
  1397. # define DBGLOG(DBGFILE, CMD) \
  1398. { if (soap)\
  1399. { if (!soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1400. soap_open_logfile((struct soap*)soap, SOAP_INDEX_##DBGFILE);\
  1401. if (soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1402. { FILE *fdebug = soap->fdebug[SOAP_INDEX_##DBGFILE];\
  1403. CMD;\
  1404. fflush(fdebug);\
  1405. }\
  1406. }\
  1407. }
  1408. # endif
  1409. # endif
  1410. # ifndef DBGMSG
  1411. # define DBGMSG(DBGFILE, MSG, LEN) \
  1412. { if (soap)\
  1413. { if (!soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1414. soap_open_logfile((struct soap*)soap, SOAP_INDEX_##DBGFILE);\
  1415. if (soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1416. { fwrite((MSG), 1, (LEN), soap->fdebug[SOAP_INDEX_##DBGFILE]);\
  1417. fflush(soap->fdebug[SOAP_INDEX_##DBGFILE]);\
  1418. }\
  1419. }\
  1420. }
  1421. # endif
  1422. # ifndef DBGFUN
  1423. # define DBGFUN(FNAME) DBGLOG(TEST, SOAP_MESSAGE(fdebug, "%s(%d): %s()\n", __FILE__, __LINE__, FNAME))
  1424. # define DBGFUN1(FNAME, FMT, ARG) DBGLOG(TEST, SOAP_MESSAGE(fdebug, "%s(%d): %s(" FMT ")\n", __FILE__, __LINE__, FNAME, (ARG)))
  1425. # define DBGFUN2(FNAME, FMT1, ARG1, FMT2, ARG2) DBGLOG(TEST, SOAP_MESSAGE(fdebug, "%s(%d): %s(" FMT1 ", " FMT2 ")\n", __FILE__, __LINE__, FNAME, (ARG1), (ARG2)))
  1426. # define DBGFUN3(FNAME, FMT1, ARG1, FMT2, ARG2, FMT3, ARG3) DBGLOG(TEST, SOAP_MESSAGE(fdebug, "%s(%d): %s(" FMT1 ", " FMT2 ", " FMT3 ")\n", __FILE__, __LINE__, FNAME, (ARG1), (ARG2), (ARG3)))
  1427. # endif
  1428. # ifndef DBGHEX
  1429. # define DBGHEX(DBGFILE, MSG, LEN) \
  1430. { if (soap)\
  1431. { if (!soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1432. soap_open_logfile(soap, SOAP_INDEX_##DBGFILE);\
  1433. if (soap->fdebug[SOAP_INDEX_##DBGFILE])\
  1434. { int i; char *s;\
  1435. for (s = (char*)(MSG), i = (LEN); i; i--)\
  1436. fprintf(soap->fdebug[SOAP_INDEX_##DBGFILE], "%2.2X ", (int)*s++&0xFF);\
  1437. fflush(soap->fdebug[SOAP_INDEX_##DBGFILE]);\
  1438. }\
  1439. }\
  1440. }
  1441. # endif
  1442. #else
  1443. # define DBGLOG(DBGFILE, CMD)
  1444. # define DBGMSG(DBGFILE, MSG, LEN)
  1445. # define DBGFUN(FNAME)
  1446. # define DBGFUN1(FNAME, FMT, ARG)
  1447. # define DBGFUN2(FNAME, FMT1, ARG1, FMT2, ARG2)
  1448. # define DBGFUN3(FNAME, FMT1, ARG1, FMT2, ARG2, FMT3, ARG3)
  1449. # define DBGHEX(DBGFILE, MSG, LEN)
  1450. #endif
  1451. /* UCS-4 requires 32 bits (0-7FFFFFFF, the sign bit is used by gSOAP to distinguish XML entities) */
  1452. typedef soap_int32 soap_wchar;
  1453. /* namespace table row */
  1454. struct Namespace
  1455. { const char *id;
  1456. const char *ns;
  1457. const char *in;
  1458. char *out;
  1459. };
  1460. /* namespace stack */
  1461. struct soap_nlist
  1462. { struct soap_nlist *next;
  1463. unsigned int level; /* nesting depth level */
  1464. short index; /* corresponding entry in ns mapping table */
  1465. const char *ns; /* only set when parsed ns URI is not in the ns mapping table */
  1466. char id[1]; /* the actual string value flows into the allocated region below this struct */
  1467. };
  1468. /* block stack for nested block allocations */
  1469. struct soap_blist
  1470. { struct soap_blist *next;
  1471. char *ptr;
  1472. size_t size;
  1473. };
  1474. /* array layout */
  1475. struct soap_array
  1476. { void *__ptr;
  1477. int __size;
  1478. };
  1479. /* pointer serialization management */
  1480. struct soap_plist
  1481. { struct soap_plist *next;
  1482. const void *ptr;
  1483. const struct soap_array *array;
  1484. int type;
  1485. int id;
  1486. char mark1; /* 0=single-ref, 1=embedded-multi-ref (SOAP1.1), 2=multi-ref, 3=attachment */
  1487. char mark2;
  1488. };
  1489. /* block allocation for pointer serialization management */
  1490. struct soap_pblk
  1491. { struct soap_pblk *next;
  1492. struct soap_plist plist[SOAP_PTRBLK];
  1493. };
  1494. #ifdef SOAP_MEM_DEBUG
  1495. /* malloc/free tracking for debugging */
  1496. struct soap_mlist
  1497. { struct soap_mlist *next;
  1498. const void *ptr;
  1499. const char *file;
  1500. int line;
  1501. short live;
  1502. };
  1503. #endif
  1504. /* class allocation list */
  1505. struct soap_clist
  1506. { struct soap_clist *next;
  1507. void *ptr;
  1508. int type;
  1509. int size;
  1510. int (*fdelete)(struct soap_clist*);
  1511. };
  1512. /* attributes */
  1513. struct soap_attribute
  1514. { struct soap_attribute *next;
  1515. short flag; /* soap_set_attr: 1 = normal, 2 = utf content */
  1516. char *value;
  1517. size_t size;
  1518. const char *ns;
  1519. short visible;
  1520. char name[1]; /* the actual name string flows into the allocated region below this struct */
  1521. };
  1522. #ifndef WITH_LEAN
  1523. struct soap_cookie
  1524. { struct soap_cookie *next;
  1525. char *name;
  1526. char *value;
  1527. char *domain;
  1528. char *path;
  1529. time_t expire; /* client-side: local time to expire */
  1530. long maxage; /* server-side: seconds to expire */
  1531. unsigned int version;
  1532. short secure;
  1533. short session; /* server-side */
  1534. short env; /* server-side: got cookie from client and should not be (re)send */
  1535. short modified; /* server-side: client cookie was modified and should be send */
  1536. };
  1537. #endif
  1538. SOAP_FMAC1 struct soap_multipart* SOAP_FMAC2 soap_next_multipart(struct soap_multipart*);
  1539. #ifdef __cplusplus
  1540. class soap_multipart_iterator
  1541. { public:
  1542. struct soap_multipart *content;
  1543. bool operator==(const soap_multipart_iterator& iter) const
  1544. { return (bool)(content == iter.content); }
  1545. bool operator!=(const soap_multipart_iterator& iter) const
  1546. { return (bool)(content != iter.content); }
  1547. struct soap_multipart &operator*() const
  1548. { return *content; }
  1549. soap_multipart_iterator &operator++()
  1550. { content = soap_next_multipart(content); return *this; }
  1551. soap_multipart_iterator() : content(NULL)
  1552. { }
  1553. soap_multipart_iterator(struct soap_multipart *p) : content(p)
  1554. { }
  1555. };
  1556. #endif
  1557. #ifndef WITH_LEANER
  1558. struct soap_dime
  1559. { size_t count;
  1560. size_t size;
  1561. size_t chunksize;
  1562. size_t buflen;
  1563. char flags;
  1564. char *ptr;
  1565. const char *id;
  1566. const char *type;
  1567. const char *options;
  1568. struct soap_multipart *list; /* list of DIME attachments received */
  1569. struct soap_multipart *first, *last; /* temporary in/out queue */
  1570. #ifdef __cplusplus
  1571. soap_multipart_iterator begin()
  1572. { soap_multipart_iterator iter(list); return iter; };
  1573. soap_multipart_iterator end()
  1574. { soap_multipart_iterator iter(NULL); return iter; };
  1575. #endif
  1576. };
  1577. #endif
  1578. #ifndef WITH_LEANER
  1579. struct soap_mime
  1580. { char *boundary; /* MIME boundary */
  1581. const char *start; /* MIME start ID */
  1582. struct soap_multipart *list; /* list of MIME attachments received */
  1583. struct soap_multipart *first, *last; /* temporary in/out queue */
  1584. #ifdef __cplusplus
  1585. soap_multipart_iterator begin()
  1586. { soap_multipart_iterator iter(list); return iter; };
  1587. soap_multipart_iterator end()
  1588. { soap_multipart_iterator iter(NULL); return iter; };
  1589. #endif
  1590. };
  1591. #endif
  1592. #ifndef WITH_LEANER
  1593. /* RFC2045 MIME content transfer encodings */
  1594. enum soap_mime_encoding
  1595. { SOAP_MIME_NONE,
  1596. SOAP_MIME_7BIT,
  1597. SOAP_MIME_8BIT,
  1598. SOAP_MIME_BINARY,
  1599. SOAP_MIME_QUOTED_PRINTABLE,
  1600. SOAP_MIME_BASE64,
  1601. SOAP_MIME_IETF_TOKEN,
  1602. SOAP_MIME_X_TOKEN
  1603. };
  1604. #endif
  1605. #ifndef WITH_LEANER
  1606. /* DIME/MIME multipart list */
  1607. struct soap_multipart
  1608. { struct soap_multipart *next;
  1609. char *ptr; /* points to raw data content */
  1610. size_t size; /* size of data content */
  1611. const char *id; /* DIME/MIME content ID or form data name */
  1612. const char *type; /* DIME/MIME type (MIME type format) */
  1613. const char *options; /* DIME options */
  1614. enum soap_mime_encoding encoding; /* MIME Content-Transfer-Encoding */
  1615. const char *location; /* MIME Content-Location (optional) */
  1616. const char *description; /* MIME Content-Description (optional) */
  1617. #ifdef __cplusplus
  1618. typedef soap_multipart_iterator iterator;
  1619. #endif
  1620. };
  1621. #endif
  1622. #ifndef WITH_LEANER
  1623. /* attachment DIME and MTOM XOP forwarding */
  1624. struct soap_xlist
  1625. { struct soap_xlist *next;
  1626. unsigned char **ptr;
  1627. int *size;
  1628. char *id;
  1629. char **type;
  1630. char **options;
  1631. };
  1632. #endif
  1633. /******************************************************************************/
  1634. #ifndef WITH_LEANER
  1635. #ifdef __cplusplus
  1636. class soap_dom_attribute_iterator
  1637. { public:
  1638. struct soap_dom_attribute *att;
  1639. const char *nstr;
  1640. const char *name;
  1641. bool operator==(const soap_dom_attribute_iterator&) const;
  1642. bool operator!=(const soap_dom_attribute_iterator&) const;
  1643. struct soap_dom_attribute &operator*() const;
  1644. soap_dom_attribute_iterator &operator++();
  1645. soap_dom_attribute_iterator();
  1646. soap_dom_attribute_iterator(struct soap_dom_attribute*);
  1647. ~soap_dom_attribute_iterator();
  1648. };
  1649. #endif
  1650. #endif
  1651. #ifndef WITH_LEANER
  1652. struct soap_dom_attribute
  1653. { struct soap_dom_attribute *next;
  1654. const char *nstr;
  1655. char *name;
  1656. char *data;
  1657. wchar_t *wide;
  1658. struct soap *soap;
  1659. #ifdef __cplusplus
  1660. typedef soap_dom_attribute_iterator iterator;
  1661. struct soap_dom_attribute &set(const char *nstr, const char *name); /* set namespace and name */
  1662. struct soap_dom_attribute &set(const char *data); /* set data */
  1663. soap_dom_attribute_iterator begin();
  1664. soap_dom_attribute_iterator end();
  1665. soap_dom_attribute_iterator find(const char *nstr, const char *name);
  1666. void unlink();
  1667. soap_dom_attribute();
  1668. soap_dom_attribute(struct soap *soap);
  1669. soap_dom_attribute(struct soap *soap, const char *nstr, const char *name, const char *data);
  1670. ~soap_dom_attribute();
  1671. #endif
  1672. };
  1673. #endif
  1674. #ifndef WITH_LEANER
  1675. #ifdef __cplusplus
  1676. class soap_dom_element_iterator
  1677. { public:
  1678. struct soap_dom_element *elt;
  1679. const char *nstr;
  1680. const char *name;
  1681. int type;
  1682. bool operator==(const soap_dom_element_iterator&) const;
  1683. bool operator!=(const soap_dom_element_iterator&) const;
  1684. struct soap_dom_element &operator*() const;
  1685. soap_dom_element_iterator &operator++();
  1686. soap_dom_element_iterator();
  1687. soap_dom_element_iterator(struct soap_dom_element*);
  1688. ~soap_dom_element_iterator();
  1689. };
  1690. #endif
  1691. #endif
  1692. #ifndef WITH_LEANER
  1693. struct soap_dom_element
  1694. { struct soap_dom_element *next; /* next sibling */
  1695. struct soap_dom_element *prnt; /* parent */
  1696. struct soap_dom_element *elts; /* list of child elements */
  1697. struct soap_dom_attribute *atts; /* list of attributes */
  1698. const char *nstr; /* namespace string */
  1699. char *name; /* element tag name */
  1700. char *data; /* element content data (with SOAP_C_UTFSTRING flag set) */
  1701. wchar_t *wide; /* element content data */
  1702. int type; /* optional: serialized C/C++ data type */
  1703. void *node; /* optional: pointer to serialized C/C++ data */
  1704. char *head; /* leading content before start tag */
  1705. char *tail; /* leading content before end tag */
  1706. struct soap *soap; /* soap context that manages this node */
  1707. #ifdef __cplusplus
  1708. typedef soap_dom_element_iterator iterator;
  1709. struct soap_dom_element &set(const char *nstr, const char *name);
  1710. struct soap_dom_element &set(const char *data);
  1711. struct soap_dom_element &set(void *node, int type);
  1712. struct soap_dom_element &add(struct soap_dom_element*);
  1713. struct soap_dom_element &add(struct soap_dom_element&);
  1714. struct soap_dom_element &add(struct soap_dom_attribute*);
  1715. struct soap_dom_element &add(struct soap_dom_attribute&);
  1716. soap_dom_element_iterator begin();
  1717. soap_dom_element_iterator end();
  1718. soap_dom_element_iterator find(const char *nstr, const char *name);
  1719. soap_dom_element_iterator find(int type);
  1720. void unlink();
  1721. soap_dom_element();
  1722. soap_dom_element(struct soap *soap);
  1723. soap_dom_element(struct soap *soap, const char *nstr, const char *name);
  1724. soap_dom_element(struct soap *soap, const char *nstr, const char *name, const char *data);
  1725. soap_dom_element(struct soap *soap, const char *nstr, const char *name, void *node, int type);
  1726. ~soap_dom_element();
  1727. #endif
  1728. };
  1729. SOAP_FMAC1 struct soap_dom_element * SOAP_FMAC2 soap_dom_next_element(struct soap_dom_element *elt);
  1730. SOAP_FMAC1 struct soap_dom_attribute * SOAP_FMAC2 soap_dom_next_attribute(struct soap_dom_attribute *att);
  1731. #endif
  1732. #if defined(__cplusplus) && !defined(WITH_LEAN) && !defined(WITH_COMPAT)
  1733. }
  1734. extern std::ostream &operator<<(std::ostream&, const struct soap_dom_element&);
  1735. extern std::istream &operator>>(std::istream&, struct soap_dom_element&);
  1736. extern "C" {
  1737. #endif
  1738. /******************************************************************************/
  1739. #ifdef WIN32
  1740. # ifdef SOAP_STD_EXPORTS
  1741. # define SOAP_STD_API __declspec(dllexport)
  1742. # else
  1743. # define SOAP_STD_API
  1744. # endif
  1745. #else
  1746. # define SOAP_STD_API
  1747. #endif
  1748. struct SOAP_STD_API soap
  1749. { short state; /* 0 = uninitialized, 1 = initialized, 2 = copy of another soap struct */
  1750. short version; /* 1 = SOAP1.1 and 2 = SOAP1.2 (set automatically from namespace URI in nsmap table), 0 indicates non-SOAP content */
  1751. soap_mode mode;
  1752. soap_mode imode;
  1753. soap_mode omode;
  1754. const char *float_format; /* user-definable format string for floats (<1024 chars) */
  1755. const char *double_format; /* user-definable format string for doubles (<1024 chars) */
  1756. const char *dime_id_format; /* user-definable format string for integer DIME id (<SOAP_TAGLEN chars) */
  1757. const char *http_version; /* HTTP version used "1.0" or "1.1" */
  1758. const char *http_content; /* optional custom response content type (with SOAP_FILE) */
  1759. const char *encodingStyle; /* default = "" which means that SOAP encoding is used */
  1760. const char *actor; /* SOAP-ENV:actor or role attribute value */
  1761. const char *lang; /* xml:lang attribute value of SOAP-ENV:Text */
  1762. int recv_timeout; /* when > 0, gives socket recv timeout in seconds, < 0 in usec */
  1763. int send_timeout; /* when > 0, gives socket send timeout in seconds, < 0 in usec */
  1764. int connect_timeout; /* when > 0, gives socket connect() timeout in seconds, < 0 in usec */
  1765. int accept_timeout; /* when > 0, gives socket accept() timeout in seconds, < 0 in usec */
  1766. int socket_flags; /* socket recv() and send() flags, e.g. set to MSG_NOSIGNAL to disable sigpipe */
  1767. int connect_flags; /* connect() SOL_SOCKET sockopt flags, e.g. set to SO_DEBUG to debug socket */
  1768. int bind_flags; /* bind() SOL_SOCKET sockopt flags, e.g. set to SO_REUSEADDR to enable reuse */
  1769. int accept_flags; /* accept() SOL_SOCKET sockopt flags */
  1770. unsigned short linger_time; /* linger time for SO_LINGER option */
  1771. const struct Namespace *namespaces; /* Pointer to global namespace mapping table */
  1772. struct Namespace *local_namespaces; /* Local namespace mapping table */
  1773. struct soap_nlist *nlist; /* namespace stack */
  1774. struct soap_blist *blist; /* block allocation stack */
  1775. struct soap_clist *clist; /* class instance allocation list */
  1776. void *alist; /* memory allocation (malloc) list */
  1777. #if !defined(WITH_LEAN) || !defined(WITH_NOIDREF)
  1778. struct soap_ilist *iht[SOAP_IDHASH];
  1779. struct soap_plist *pht[SOAP_PTRHASH];
  1780. struct soap_pblk *pblk; /* plist block allocation */
  1781. short pidx; /* plist block allocation */
  1782. #endif
  1783. struct SOAP_ENV__Header *header;
  1784. struct SOAP_ENV__Fault *fault;
  1785. int idnum;
  1786. void *user; /* for user to pass user-defined data */
  1787. void *data[4]; /* extension data = {smdevp, mecevp, ...} */
  1788. struct soap_plugin *plugins; /* linked list of plug-in data */
  1789. const char *userid; /* HTTP Basic authorization userid */
  1790. const char *passwd; /* HTTP Basic authorization passwd */
  1791. const char *authrealm; /* HTTP authentication realm (NTLM domain) */
  1792. #if !defined(WITH_LEAN) || defined(WITH_NTLM)
  1793. const char *ntlm_challenge; /* HTTP NTLM challenge key string */
  1794. short ntlm_auth; /* HTTP NTLM authentication type */
  1795. short ntlm_stage; /* HTTP NTLM stage 0..3 */
  1796. #endif
  1797. int (*fpost)(struct soap*, const char*, const char*, int, const char*, const char*, size_t);
  1798. int (*fget)(struct soap*); /* HTTP GET hook (not set by default) */
  1799. int (*fput)(struct soap*); /* HTTP PUT hook (handled as POST by default) */
  1800. int (*fdel)(struct soap*); /* HTTP DELETE hook (not set by default) */
  1801. int (*fopt)(struct soap*); /* HTTP OPTIONS hook (not set by default) */
  1802. int (*fhead)(struct soap*); /* HTTP HEAD hook (not set by default) */
  1803. int (*fform)(struct soap*); /* HTTP/HTML form handler for plugins */
  1804. int (*fposthdr)(struct soap*, const char*, const char*);
  1805. int (*fresponse)(struct soap*, int, size_t);
  1806. int (*fparse)(struct soap*);
  1807. int (*fparsehdr)(struct soap*, const char*, const char*);
  1808. int (*fheader)(struct soap*);
  1809. int (*fresolve)(struct soap*, const char*, struct in_addr* inaddr);
  1810. int (*fconnect)(struct soap*, const char*, const char*, int);
  1811. int (*fdisconnect)(struct soap*);
  1812. int (*fclosesocket)(struct soap*, SOAP_SOCKET);
  1813. int (*fshutdownsocket)(struct soap*, SOAP_SOCKET, int);
  1814. SOAP_SOCKET (*fopen)(struct soap*, const char*, const char*, int);
  1815. SOAP_SOCKET (*faccept)(struct soap*, SOAP_SOCKET, struct sockaddr*, int *n);
  1816. int (*fclose)(struct soap*);
  1817. int (*fsend)(struct soap*, const char*, size_t);
  1818. size_t (*frecv)(struct soap*, char*, size_t);
  1819. int (*fpoll)(struct soap*);
  1820. void (*fseterror)(struct soap*, const char **c, const char **s);
  1821. int (*fignore)(struct soap*, const char*);
  1822. int (*fserveloop)(struct soap*);
  1823. void *(*fplugin)(struct soap*, const char*);
  1824. void *(*fmalloc)(struct soap*, size_t);
  1825. #ifndef WITH_LEANER
  1826. int (*feltbegin)(struct soap*, const char*);
  1827. int (*feltendin)(struct soap*, const char*, const char*);
  1828. int (*feltbegout)(struct soap*, const char*);
  1829. int (*feltendout)(struct soap*, const char*);
  1830. int (*fprepareinitsend)(struct soap*);
  1831. int (*fprepareinitrecv)(struct soap*);
  1832. int (*fpreparesend)(struct soap*, const char*, size_t);
  1833. int (*fpreparerecv)(struct soap*, const char*, size_t);
  1834. int (*fpreparefinalsend)(struct soap*);
  1835. int (*fpreparefinalrecv)(struct soap*);
  1836. int filterstop;
  1837. int (*ffiltersend)(struct soap*, const char**, size_t*);
  1838. int (*ffilterrecv)(struct soap*, char*, size_t*, size_t);
  1839. void *(*fdimereadopen)(struct soap*, void*, const char*, const char*, const char*);
  1840. void *(*fdimewriteopen)(struct soap*, const char*, const char*, const char*);
  1841. void (*fdimereadclose)(struct soap*, void*);
  1842. void (*fdimewriteclose)(struct soap*, void*);
  1843. size_t (*fdimeread)(struct soap*, void*, char*, size_t);
  1844. int (*fdimewrite)(struct soap*, void*, const char*, size_t);
  1845. void *(*fmimereadopen)(struct soap*, void*, const char*, const char*, const char*);
  1846. void *(*fmimewriteopen)(struct soap*, void*, const char*, const char*, const char*, enum soap_mime_encoding);
  1847. void (*fmimereadclose)(struct soap*, void*);
  1848. void (*fmimewriteclose)(struct soap*, void*);
  1849. size_t (*fmimeread)(struct soap*, void*, char*, size_t);
  1850. int (*fmimewrite)(struct soap*, void*, const char*, size_t);
  1851. #endif
  1852. SOAP_SOCKET master; /* socket bound to TCP/IP port */
  1853. SOAP_SOCKET socket; /* socket to send and receive */
  1854. SOAP_SOCKET sendsk; /* socket to send (overrides ::socket) */
  1855. SOAP_SOCKET recvsk; /* socket to receive (overrides ::socket) */
  1856. #if defined(__cplusplus) && !defined(WITH_LEAN) && !defined(WITH_COMPAT)
  1857. std::ostream *os; /* stream to send */
  1858. std::istream *is; /* stream to receive */
  1859. #else
  1860. void *os; /* preserve struct size */
  1861. void *is; /* preserve struct size */
  1862. #endif
  1863. #ifndef UNDER_CE
  1864. int sendfd; /* WinCE FD to send */
  1865. int recvfd; /* WinCE FD to receive */
  1866. #else
  1867. FILE *sendfd; /* FD to send */
  1868. FILE *recvfd; /* FD to receive */
  1869. #endif
  1870. size_t bufidx; /* index in soap.buf[] */
  1871. size_t buflen; /* length of soap.buf[] content */
  1872. soap_wchar ahead; /* parser lookahead */
  1873. short cdata; /* CDATA parser state */
  1874. short body; /* HTTP or XML element has a body (1) or not (0) */
  1875. unsigned int level; /* XML nesting level */
  1876. size_t count; /* message length counter */
  1877. size_t length; /* message length as set by HTTP header */
  1878. char *labbuf; /* look-aside buffer */
  1879. size_t lablen; /* look-aside buffer allocated length */
  1880. size_t labidx; /* look-aside buffer index to available part */
  1881. char buf[SOAP_BUFLEN];/* send and receive buffer */
  1882. char msgbuf[1024]; /* in/out buffer for HTTP/MIME headers >=1024 bytes */
  1883. char tmpbuf[1024]; /* in/out buffer for HTTP/MIME headers, simpleType values, element and attribute tag names, and DIME must be >=1024 bytes */
  1884. char tag[SOAP_TAGLEN];
  1885. char id[SOAP_TAGLEN];
  1886. char href[SOAP_TAGLEN];
  1887. char type[SOAP_TAGLEN];
  1888. char arrayType[SOAP_TAGLEN];
  1889. char arraySize[SOAP_TAGLEN];
  1890. char arrayOffset[SOAP_TAGLEN];
  1891. short other;
  1892. short root;
  1893. int position;
  1894. int positions[SOAP_MAXDIMS];
  1895. struct soap_attribute *attributes; /* attribute list */
  1896. short encoding; /* when set, output encodingStyle */
  1897. short mustUnderstand; /* a mustUnderstand element was parsed or is output */
  1898. short null; /* parsed XML is xsi:nil */
  1899. short ns; /* when not set, output full xmlns bindings */
  1900. short part; /* SOAP part state (header or body) */
  1901. short event; /* engine events and states for use by plugins */
  1902. unsigned int evlev; /* event level */
  1903. short alloced;
  1904. short peeked;
  1905. size_t chunksize;
  1906. size_t chunkbuflen;
  1907. char endpoint[SOAP_TAGLEN];
  1908. char path[SOAP_TAGLEN];
  1909. char host[SOAP_TAGLEN];
  1910. char *action;
  1911. char *prolog; /* XML declaration prolog */
  1912. unsigned long ip; /* IP number */
  1913. int port; /* port number */
  1914. short keep_alive; /* connection should be kept open */
  1915. short tcp_keep_alive; /* enable SO_KEEPALIVE */
  1916. unsigned int tcp_keep_idle; /* set TCP_KEEPIDLE */
  1917. unsigned int tcp_keep_intvl; /* set TCP_KEEPINTVL */
  1918. unsigned int tcp_keep_cnt; /* set TCP_KEEPCNT */
  1919. unsigned int max_keep_alive; /* maximum keep-alive session (default=100) */
  1920. const char *proxy_http_version;/* HTTP version of proxy "1.0" or "1.1" */
  1921. const char *proxy_host; /* Proxy Server host name */
  1922. int proxy_port; /* Proxy Server port (default = 8080) */
  1923. const char *proxy_userid; /* Proxy Authorization user name */
  1924. const char *proxy_passwd; /* Proxy Authorization password */
  1925. const char *proxy_from; /* X-Forwarding-For header returned by proxy */
  1926. int status; /* -1 when request, else error code to be returned by server */
  1927. int error;
  1928. int errmode;
  1929. int errnum;
  1930. #ifndef WITH_LEANER
  1931. struct soap_dom_element *dom;
  1932. struct soap_dime dime;
  1933. struct soap_mime mime;
  1934. struct soap_xlist *xlist;
  1935. #endif
  1936. #if !defined(WITH_LEAN) || defined(SOAP_DEBUG)
  1937. const char *logfile[SOAP_MAXLOGS];
  1938. FILE *fdebug[SOAP_MAXLOGS];
  1939. struct soap_mlist *mht[SOAP_PTRHASH];
  1940. #endif
  1941. #ifndef WITH_LEAN
  1942. const char *wsuid; /* space-separated string of element tags */
  1943. const char *c14nexclude; /* space-separated string of prefixes */
  1944. struct soap_cookie *cookies;
  1945. const char *cookie_domain;
  1946. const char *cookie_path;
  1947. int cookie_max;
  1948. #endif
  1949. #ifndef WITH_NOIO
  1950. unsigned int ipv6_multicast_if; /* in_addr_t in6addr->sin6_scope_id IPv6 value */
  1951. char* ipv4_multicast_if; /* IP_MULTICAST_IF IPv4 setsockopt interface_addr */
  1952. unsigned char ipv4_multicast_ttl; /* IP_MULTICAST_TTL value 0..255 */
  1953. #ifdef WITH_IPV6
  1954. struct sockaddr_storage peer; /* IPv6: set by soap_accept and by UDP recv */
  1955. #else
  1956. struct sockaddr_in peer; /* IPv4: set by soap_connect/soap_accept and by UDP recv */
  1957. #endif
  1958. #endif
  1959. size_t peerlen;
  1960. #if defined(WITH_OPENSSL) /* OpenSSL */
  1961. int (*fsslauth)(struct soap*);
  1962. int (*fsslverify)(int, X509_STORE_CTX*);
  1963. BIO *bio;
  1964. SSL *ssl;
  1965. SSL_CTX *ctx;
  1966. SSL_SESSION *session;
  1967. const char *dhfile;
  1968. const char *randfile;
  1969. #elif defined(WITH_GNUTLS) /* GNUTLS */
  1970. int (*fsslauth)(struct soap*);
  1971. void *fsslverify;
  1972. gnutls_certificate_credentials_t xcred; /* cert pointer */
  1973. gnutls_anon_client_credentials_t acred; /* anon pointer */
  1974. gnutls_priority_t cache; /* priority cache pointer */
  1975. gnutls_session_t session; /* session pointer */
  1976. gnutls_dh_params_t dh_params;
  1977. gnutls_rsa_params_t rsa_params;
  1978. #else /* No SSL/TLS */
  1979. void *fsslauth; /* dummy members, to preserve struct size */
  1980. void *fsslverify;
  1981. void *bio;
  1982. void *ssl;
  1983. void *ctx;
  1984. void *session;
  1985. void *dh_params;
  1986. void *rsa_params;
  1987. #endif
  1988. unsigned short ssl_flags;
  1989. const char *keyfile;
  1990. const char *keyid;
  1991. const char *password;
  1992. const char *cafile;
  1993. const char *capath;
  1994. const char *crlfile;
  1995. char session_host[SOAP_TAGLEN];
  1996. int session_port;
  1997. #ifdef WITH_C_LOCALE
  1998. # ifdef WIN32
  1999. _locale_t c_locale; /* set to C locale by default */
  2000. # else
  2001. locale_t c_locale; /* set to C locale by default */
  2002. # endif
  2003. #else
  2004. void *c_locale;
  2005. #endif
  2006. #ifdef WITH_ZLIB
  2007. z_stream *d_stream; /* decompression stream */
  2008. uLong z_crc; /* internal gzip crc */
  2009. #else
  2010. void *d_stream; /* dummy members, to preserve struct size */
  2011. soap_int32 z_crc;
  2012. #endif
  2013. const char *z_dict; /* support for zlib static dictionaries */
  2014. unsigned int z_dict_len;
  2015. short zlib_state; /* SOAP_ZLIB_NONE, SOAP_ZLIB_DEFLATE, or SOAP_ZLIB_INFLATE */
  2016. short zlib_in; /* SOAP_ZLIB_NONE, SOAP_ZLIB_DEFLATE, or SOAP_ZLIB_GZIP */
  2017. short zlib_out; /* SOAP_ZLIB_NONE, SOAP_ZLIB_DEFLATE, or SOAP_ZLIB_GZIP */
  2018. char *z_buf; /* buffer */
  2019. size_t z_buflen;
  2020. unsigned short z_level; /* compression level to be used (0=none, 1=fast to 9=best) */
  2021. float z_ratio_in; /* detected compression ratio compressed_length/length of inbound message */
  2022. float z_ratio_out; /* detected compression ratio compressed_length/length of outbound message */
  2023. #ifdef WMW_RPM_IO /* VxWorks */
  2024. void *rpmreqid;
  2025. #endif
  2026. #ifdef __cplusplus
  2027. soap();
  2028. soap(soap_mode);
  2029. soap(soap_mode, soap_mode);
  2030. soap(const struct soap&);
  2031. virtual ~soap();
  2032. #else
  2033. void (*dummy)(void);
  2034. #endif
  2035. };
  2036. struct soap_code_map
  2037. { long code;
  2038. const char *string;
  2039. };
  2040. /* forwarding list */
  2041. struct soap_flist
  2042. { struct soap_flist *next;
  2043. int type;
  2044. void *ptr;
  2045. unsigned int level;
  2046. size_t len;
  2047. void (*fcopy)(struct soap*, int, int, void*, size_t, const void*, size_t);
  2048. };
  2049. /* id-ref forwarding list */
  2050. struct soap_ilist
  2051. { struct soap_ilist *next;
  2052. int type;
  2053. size_t size;
  2054. void *link;
  2055. void *copy;
  2056. struct soap_flist *flist;
  2057. void *ptr;
  2058. unsigned int level;
  2059. char id[1]; /* the actual id string value flows into the allocated region below this struct */
  2060. };
  2061. struct soap_plugin
  2062. { struct soap_plugin *next;
  2063. const char *id;
  2064. void *data;
  2065. int (*fcopy)(struct soap *soap, struct soap_plugin *dst, struct soap_plugin *src);
  2066. void (*fdelete)(struct soap *soap, struct soap_plugin *p); /* should delete fields of plugin only and not free(p) */
  2067. };
  2068. extern SOAP_NMAC struct Namespace namespaces[];
  2069. #ifndef WITH_LEAN
  2070. # define soap_get0(soap) (((soap)->bufidx>=(soap)->buflen && soap_recv(soap)) ? EOF : (unsigned char)(soap)->buf[(soap)->bufidx])
  2071. # define soap_get1(soap) (((soap)->bufidx>=(soap)->buflen && soap_recv(soap)) ? EOF : (unsigned char)(soap)->buf[(soap)->bufidx++])
  2072. #else
  2073. soap_wchar soap_get0(struct soap*);
  2074. soap_wchar soap_get1(struct soap*);
  2075. #endif
  2076. #define SOAP_XSTRINGIFY(s) SOAP_STRINGIFY(s)
  2077. #define SOAP_STRINGIFY(s) #s
  2078. #define soap_versioning_paste(name, ext) name##_LIBRARY_VERSION_REQUIRED_##ext
  2079. #define soap_versioning_ext(name, ext) soap_versioning_paste(name, ext)
  2080. #define soap_versioning(name) soap_versioning_ext(name, GSOAP_VERSION)
  2081. #define soap_init(soap) soap_init1(soap, SOAP_IO_DEFAULT)
  2082. #define soap_init1(soap, mode) soap_init2(soap, mode, mode)
  2083. #define soap_init2(soap, imode, omode) soap_versioning(soap_init)(soap, imode, omode)
  2084. #define soap_new() soap_new1(SOAP_IO_DEFAULT)
  2085. #define soap_new1(mode) soap_new2(mode, mode)
  2086. #define soap_new2(imode, omode) soap_versioning(soap_new)(imode, omode)
  2087. #define soap_revget1(soap) ((soap)->bufidx--)
  2088. #define soap_unget(soap, c) ((soap)->ahead = c)
  2089. #define soap_register_plugin(soap, plugin) soap_register_plugin_arg(soap, plugin, NULL)
  2090. #define soap_mode(soap, n) ((soap)->mode = (soap)->imode = (soap)->omode = (n))
  2091. #define soap_imode(soap, n) ((soap)->imode = (n))
  2092. #define soap_omode(soap, n) ((soap)->omode = (n))
  2093. #define soap_set_imode(soap, n) ((soap)->imode |= (n))
  2094. #define soap_clr_imode(soap, n) ((soap)->imode &= ~(n))
  2095. #define soap_set_omode(soap, n) ((soap)->omode |= (n))
  2096. #define soap_clr_omode(soap, n) ((soap)->omode &= ~(n))
  2097. #define soap_set_mode(soap, n) ((soap)->imode |= (n), (soap)->omode |= (n))
  2098. #define soap_clr_mode(soap, n) ((soap)->imode &= ~(n), (soap)->omode &= ~(n))
  2099. #define soap_destroy(soap) soap_delete((soap), NULL)
  2100. #ifdef HAVE_STRRCHR
  2101. # define soap_strrchr(s, t) strrchr(s, t)
  2102. #else
  2103. SOAP_FMAC1 char* SOAP_FMAC2 soap_strrchr(const char *s, int t);
  2104. #endif
  2105. #ifdef HAVE_STRTOL
  2106. # define soap_strtol(s, t, b) strtol(s, t, b)
  2107. #else
  2108. SOAP_FMAC1 long SOAP_FMAC2 soap_strtol(const char *s, char **t, int b);
  2109. #endif
  2110. #ifdef HAVE_STRTOUL
  2111. # define soap_strtoul(s, t, b) strtoul(s, t, b)
  2112. #else
  2113. SOAP_FMAC1 unsigned long SOAP_FMAC2 soap_strtoul(const char *s, char **t, int b);
  2114. #endif
  2115. #if defined(WIN32) && !defined(__MINGW32__)
  2116. # define soap_strtoll _strtoi64
  2117. #else
  2118. # define soap_strtoll strtoll
  2119. #endif
  2120. #if defined(WIN32) && !defined(__MINGW32__)
  2121. # define soap_strtoull _strtoui64
  2122. #else
  2123. # define soap_strtoull strtoull
  2124. #endif
  2125. #if defined(WITH_OPENSSL)
  2126. # define soap_random soap_rand()
  2127. SOAP_FMAC1 int SOAP_FMAC2 soap_rand(void);
  2128. #elif defined(HAVE_RANDOM)
  2129. # define soap_random (int)random()
  2130. #else
  2131. # define soap_random rand()
  2132. #endif
  2133. #ifdef WITH_NOIDREF
  2134. # define soap_embedded(s, p, t) (0)
  2135. # define soap_id_lookup(s, i, p, t, n, k) (p)
  2136. # define soap_id_forward(s, h, p, len, st, tt, n, k, fc) (p)
  2137. # define soap_reference(s, a, t) (1)
  2138. # define soap_array_reference(s, p, a, n, t) (1)
  2139. # define soap_embed(s, p, a, n, t, pp) (0)
  2140. # define soap_embedded_id(s, i, p, t) (i)
  2141. # define soap_is_embedded(s, p) (0)
  2142. # define soap_is_single(s, p) (1)
  2143. # define soap_lookup_type(s, i) (0)
  2144. # define soap_getindependent(s) (0)
  2145. # define soap_putindependent(s) (0)
  2146. # define soap_markelement(s, p, n) (0)
  2147. #endif
  2148. /* soap_traverse() traversal/walker routines take walker function arguments */
  2149. typedef void soap_walker(struct soap*, void*, int, const char*, const char*);
  2150. SOAP_FMAC5 int SOAP_FMAC6 soap_serve(struct soap *soap);
  2151. SOAP_FMAC5 int SOAP_FMAC6 soap_serve_request(struct soap *soap);
  2152. SOAP_FMAC3 void SOAP_FMAC4 soap_header(struct soap*);
  2153. SOAP_FMAC3 void SOAP_FMAC4 soap_fault(struct soap*);
  2154. SOAP_FMAC3 const char** SOAP_FMAC4 soap_faultcode(struct soap*);
  2155. SOAP_FMAC3 const char** SOAP_FMAC4 soap_faultsubcode(struct soap*);
  2156. SOAP_FMAC3 const char** SOAP_FMAC4 soap_faultstring(struct soap*);
  2157. SOAP_FMAC3 const char** SOAP_FMAC4 soap_faultdetail(struct soap*);
  2158. SOAP_FMAC3 const char* SOAP_FMAC4 soap_check_faultsubcode(struct soap*);
  2159. SOAP_FMAC3 const char* SOAP_FMAC4 soap_check_faultdetail(struct soap*);
  2160. SOAP_FMAC3 void SOAP_FMAC4 soap_serializefault(struct soap*);
  2161. SOAP_FMAC1 void SOAP_FMAC2 soap_serializeheader(struct soap*);
  2162. SOAP_FMAC1 int SOAP_FMAC2 soap_getheader(struct soap*);
  2163. SOAP_FMAC1 int SOAP_FMAC2 soap_putheader(struct soap*);
  2164. SOAP_FMAC1 int SOAP_FMAC2 soap_getfault(struct soap*);
  2165. SOAP_FMAC1 int SOAP_FMAC2 soap_putfault(struct soap*);
  2166. SOAP_FMAC1 void SOAP_FMAC2 soap_ssl_init(void);
  2167. SOAP_FMAC1 int SOAP_FMAC2 soap_poll(struct soap*);
  2168. SOAP_FMAC1 int SOAP_FMAC2 soap_connect_command(struct soap*, int, const char*, const char*);
  2169. SOAP_FMAC1 int SOAP_FMAC2 soap_connect(struct soap*, const char*, const char*);
  2170. SOAP_FMAC1 SOAP_SOCKET SOAP_FMAC2 soap_bind(struct soap*, const char*, int, int);
  2171. SOAP_FMAC1 SOAP_SOCKET SOAP_FMAC2 soap_accept(struct soap*);
  2172. SOAP_FMAC1 int SOAP_FMAC2 soap_ssl_accept(struct soap*);
  2173. SOAP_FMAC1 const char * SOAP_FMAC2 soap_ssl_error(struct soap*, int);
  2174. #if defined(VXWORKS) && defined(WM_SECURE_KEY_STORAGE)
  2175. SOAP_FMAC1 int SOAP_FMAC2 soap_ssl_server_context(struct soap *soap, unsigned short flags, const char *keyfile, const char *keyid, const char *password, const char *cafile, const char *capath, const char *dhfile, const char *randfile, const char *sid);
  2176. #else
  2177. SOAP_FMAC1 int SOAP_FMAC2 soap_ssl_server_context(struct soap *soap, unsigned short flags, const char *keyfile, const char *password, const char *cafile, const char *capath, const char *dhfile, const char *randfile, const char *sid);
  2178. #endif
  2179. #if defined(VXWORKS) && defined(WM_SECURE_KEY_STORAGE)
  2180. SOAP_FMAC1 int SOAP_FMAC2 soap_ssl_client_context(struct soap *soap, unsigned short flags, const char *keyfile, const char *keyid, const char *password, const char *cafile, const char *capath, const char *randfile);
  2181. #else
  2182. SOAP_FMAC1 int SOAP_FMAC2 soap_ssl_client_context(struct soap *soap, unsigned short flags, const char *keyfile, const char *password, const char *cafile, const char *capath, const char *randfile);
  2183. #endif
  2184. SOAP_FMAC1 int SOAP_FMAC2 soap_puthttphdr(struct soap*, int status, size_t count);
  2185. SOAP_FMAC1 const char* SOAP_FMAC2 soap_get_header_attribute(struct soap*, const char*, const char*);
  2186. SOAP_FMAC1 const char* SOAP_FMAC2 soap_decode_key(char*, size_t, const char*);
  2187. SOAP_FMAC1 const char* SOAP_FMAC2 soap_decode_val(char*, size_t, const char*);
  2188. SOAP_FMAC1 size_t SOAP_FMAC2 soap_hash(const char*);
  2189. SOAP_FMAC1 void SOAP_FMAC2 soap_set_endpoint(struct soap*, const char*);
  2190. SOAP_FMAC1 int SOAP_FMAC2 soap_flush_raw(struct soap*, const char*, size_t);
  2191. SOAP_FMAC1 int SOAP_FMAC2 soap_flush(struct soap*);
  2192. SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_get(struct soap*);
  2193. SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_getchar(struct soap*);
  2194. SOAP_FMAC1 int SOAP_FMAC2 soap_tag_cmp(const char*, const char*);
  2195. SOAP_FMAC1 void SOAP_FMAC2 soap_set_fault(struct soap*);
  2196. SOAP_FMAC1 int SOAP_FMAC2 soap_sender_fault(struct soap*, const char*, const char*);
  2197. SOAP_FMAC1 int SOAP_FMAC2 soap_sender_fault_subcode(struct soap*, const char*, const char*, const char*);
  2198. SOAP_FMAC1 int SOAP_FMAC2 soap_receiver_fault(struct soap*, const char*, const char*);
  2199. SOAP_FMAC1 int SOAP_FMAC2 soap_receiver_fault_subcode(struct soap*, const char*, const char*, const char*);
  2200. SOAP_FMAC1 int SOAP_FMAC2 soap_set_sender_error(struct soap*, const char*, const char*, int);
  2201. SOAP_FMAC1 int SOAP_FMAC2 soap_set_receiver_error(struct soap*, const char*, const char*, int);
  2202. SOAP_FMAC1 int SOAP_FMAC2 soap_send_raw(struct soap*, const char*, size_t);
  2203. SOAP_FMAC1 int SOAP_FMAC2 soap_recv_raw(struct soap*);
  2204. SOAP_FMAC1 int SOAP_FMAC2 soap_recv(struct soap*);
  2205. SOAP_FMAC1 int SOAP_FMAC2 soap_send(struct soap*, const char*);
  2206. SOAP_FMAC1 int SOAP_FMAC2 soap_send2(struct soap*, const char*, const char*);
  2207. SOAP_FMAC1 int SOAP_FMAC2 soap_send3(struct soap*, const char*, const char*, const char*);
  2208. SOAP_FMAC1 int SOAP_FMAC2 soap_pututf8(struct soap*, unsigned long);
  2209. SOAP_FMAC1 soap_wchar SOAP_FMAC2 soap_getutf8(struct soap*);
  2210. SOAP_FMAC1 int SOAP_FMAC2 soap_putbase64(struct soap*, const unsigned char*, int);
  2211. SOAP_FMAC1 unsigned char* SOAP_FMAC2 soap_getbase64(struct soap*, int*, int);
  2212. SOAP_FMAC1 int SOAP_FMAC2 soap_puthex(struct soap*, const unsigned char*, int);
  2213. SOAP_FMAC1 unsigned char* SOAP_FMAC2 soap_gethex(struct soap*, int*);
  2214. #ifndef WITH_LEANER
  2215. SOAP_FMAC1 int SOAP_FMAC2 soap_xop_forward(struct soap*, unsigned char**, int*, char**, char**, char**);
  2216. SOAP_FMAC1 int SOAP_FMAC2 soap_dime_forward(struct soap*, unsigned char**, int*, char**, char**, char**);
  2217. #endif
  2218. #ifndef WITH_NOIDREF
  2219. SOAP_FMAC1 int SOAP_FMAC2 soap_pointer_lookup_id(struct soap*, void *p, int t, struct soap_plist**);
  2220. SOAP_FMAC1 int SOAP_FMAC2 soap_pointer_lookup(struct soap*, const void *p, int t, struct soap_plist**);
  2221. SOAP_FMAC1 int SOAP_FMAC2 soap_pointer_enter(struct soap*, const void *p, const struct soap_array *a, int n, int t, struct soap_plist**);
  2222. SOAP_FMAC1 int SOAP_FMAC2 soap_array_pointer_lookup(struct soap*, const void *p, const struct soap_array *a, int n, int t, struct soap_plist**);
  2223. SOAP_FMAC1 int SOAP_FMAC2 soap_embed(struct soap *soap, const void *p, const struct soap_array *a, int n, const char *tag, int type);
  2224. SOAP_FMAC1 struct soap_ilist* SOAP_FMAC2 soap_lookup(struct soap*, const char*);
  2225. SOAP_FMAC1 struct soap_ilist* SOAP_FMAC2 soap_enter(struct soap*, const char*);
  2226. SOAP_FMAC1 int SOAP_FMAC2 soap_resolve(struct soap*);
  2227. SOAP_FMAC1 void SOAP_FMAC2 soap_embedded(struct soap*, const void *p, int t);
  2228. SOAP_FMAC1 int SOAP_FMAC2 soap_reference(struct soap*, const void *p, int t);
  2229. SOAP_FMAC1 int SOAP_FMAC2 soap_array_reference(struct soap*, const void *p, const struct soap_array *a, int n, int t);
  2230. SOAP_FMAC1 int SOAP_FMAC2 soap_embedded_id(struct soap*, int id, const void *p, int t);
  2231. SOAP_FMAC1 int SOAP_FMAC2 soap_is_embedded(struct soap*, struct soap_plist*);
  2232. SOAP_FMAC1 int SOAP_FMAC2 soap_is_single(struct soap*, struct soap_plist*);
  2233. SOAP_FMAC1 void SOAP_FMAC2 soap_set_embedded(struct soap*, struct soap_plist*);
  2234. #endif
  2235. SOAP_FMAC1 int SOAP_FMAC2 soap_begin_count(struct soap*);
  2236. SOAP_FMAC1 int SOAP_FMAC2 soap_end_count(struct soap*);
  2237. SOAP_FMAC1 int SOAP_FMAC2 soap_begin_send(struct soap*);
  2238. SOAP_FMAC1 int SOAP_FMAC2 soap_end_send(struct soap*);
  2239. SOAP_FMAC1 int SOAP_FMAC2 soap_end_send_flush(struct soap*);
  2240. SOAP_FMAC1 const struct soap_code_map* SOAP_FMAC2 soap_code(const struct soap_code_map*, const char*);
  2241. SOAP_FMAC1 long SOAP_FMAC2 soap_code_int(const struct soap_code_map*, const char*, long);
  2242. SOAP_FMAC1 const char* SOAP_FMAC2 soap_code_str(const struct soap_code_map*, long);
  2243. SOAP_FMAC1 long SOAP_FMAC2 soap_code_bits(const struct soap_code_map*, const char*);
  2244. SOAP_FMAC1 const char* SOAP_FMAC2 soap_code_list(struct soap*, const struct soap_code_map*, long);
  2245. SOAP_FMAC1 int SOAP_FMAC2 soap_getline(struct soap*, char*, int);
  2246. SOAP_FMAC1 int SOAP_FMAC2 soap_begin_serve(struct soap*);
  2247. SOAP_FMAC1 int SOAP_FMAC2 soap_begin_recv(struct soap*);
  2248. SOAP_FMAC1 int SOAP_FMAC2 soap_end_recv(struct soap*);
  2249. SOAP_FMAC1 void* SOAP_FMAC2 soap_malloc(struct soap*, size_t);
  2250. SOAP_FMAC1 void SOAP_FMAC2 soap_dealloc(struct soap*, void*);
  2251. SOAP_FMAC1 struct soap_clist * SOAP_FMAC2 soap_link(struct soap*, void*, int, int, int (*fdelete)(struct soap_clist*));
  2252. SOAP_FMAC1 int SOAP_FMAC2 soap_unlink(struct soap*, const void*);
  2253. SOAP_FMAC1 void SOAP_FMAC2 soap_free_temp(struct soap*);
  2254. SOAP_FMAC1 void SOAP_FMAC2 soap_del(struct soap*);
  2255. SOAP_FMAC1 void* SOAP_FMAC2 soap_track_malloc(struct soap*, const char*, int, size_t);
  2256. SOAP_FMAC1 void SOAP_FMAC2 soap_track_free(struct soap*, const char*, int, void*);
  2257. #ifndef WITH_NOIDREF
  2258. SOAP_FMAC1 int SOAP_FMAC2 soap_lookup_type(struct soap*, const char *id);
  2259. SOAP_FMAC1 void* SOAP_FMAC2 soap_id_lookup(struct soap*, const char *id, void **p, int t, size_t n, unsigned int k);
  2260. SOAP_FMAC1 void* SOAP_FMAC2 soap_id_forward(struct soap*, const char *id, void *p, size_t len, int st, int tt, size_t n, unsigned int k, void(*fcopy)(struct soap*, int, int, void*, size_t, const void*, size_t));
  2261. #endif
  2262. SOAP_FMAC1 void* SOAP_FMAC2 soap_id_enter(struct soap*, const char *id, void *p, int t, size_t n, unsigned int k, const char *type, const char *arrayType, void *(*finstantiate)(struct soap*, int, const char*, const char*, size_t*));
  2263. SOAP_FMAC1 void SOAP_FMAC2 soap_fcopy(struct soap *soap, int st, int tt, void *p, size_t, const void *q, size_t n);
  2264. SOAP_FMAC1 int SOAP_FMAC2 soap_size(const int *, int);
  2265. SOAP_FMAC1 int SOAP_FMAC2 soap_getoffsets(const char *, const int *, int *, int);
  2266. SOAP_FMAC1 int SOAP_FMAC2 soap_getsize(const char *, const char *, int *);
  2267. SOAP_FMAC1 int SOAP_FMAC2 soap_getsizes(const char *, int *, int);
  2268. SOAP_FMAC1 int SOAP_FMAC2 soap_getposition(const char *, int *);
  2269. SOAP_FMAC1 char* SOAP_FMAC2 soap_putsize(struct soap*, const char *, int);
  2270. SOAP_FMAC1 char* SOAP_FMAC2 soap_putsizesoffsets(struct soap*, const char *, const int *, const int *, int);
  2271. SOAP_FMAC1 char* SOAP_FMAC2 soap_putsizes(struct soap*, const char *, const int *, int);
  2272. SOAP_FMAC1 char* SOAP_FMAC2 soap_putoffset(struct soap*, int);
  2273. SOAP_FMAC1 char* SOAP_FMAC2 soap_putoffsets(struct soap*, const int *, int);
  2274. SOAP_FMAC1 int SOAP_FMAC2 soap_closesock(struct soap*);
  2275. SOAP_FMAC1 int SOAP_FMAC2 soap_force_closesock(struct soap*);
  2276. SOAP_FMAC1 struct soap *SOAP_FMAC2 soap_versioning(soap_new)(soap_mode, soap_mode);
  2277. SOAP_FMAC1 void SOAP_FMAC2 soap_free(struct soap*);
  2278. SOAP_FMAC1 struct soap *SOAP_FMAC2 soap_copy(const struct soap*);
  2279. SOAP_FMAC1 struct soap *SOAP_FMAC2 soap_copy_context(struct soap*, const struct soap*);
  2280. SOAP_FMAC1 void SOAP_FMAC2 soap_copy_stream(struct soap*, struct soap*);
  2281. SOAP_FMAC1 void SOAP_FMAC2 soap_free_stream(struct soap*);
  2282. SOAP_FMAC1 void SOAP_FMAC2 soap_versioning(soap_init)(struct soap*, soap_mode, soap_mode);
  2283. SOAP_FMAC1 void SOAP_FMAC2 soap_initialize(struct soap*);
  2284. SOAP_FMAC1 void SOAP_FMAC2 soap_done(struct soap*);
  2285. SOAP_FMAC1 void SOAP_FMAC2 soap_cleanup(struct soap*);
  2286. SOAP_FMAC1 void SOAP_FMAC2 soap_begin(struct soap*);
  2287. SOAP_FMAC1 void SOAP_FMAC2 soap_end(struct soap*);
  2288. SOAP_FMAC1 void SOAP_FMAC2 soap_delete(struct soap*, void*);
  2289. SOAP_FMAC1 void SOAP_FMAC2 soap_delegate_deletion(struct soap*, struct soap*);
  2290. /* API functions available with DEBUG or SOAP_DEBUG defined: */
  2291. SOAP_FMAC1 void SOAP_FMAC2 soap_set_recv_logfile(struct soap*, const char*);
  2292. SOAP_FMAC1 void SOAP_FMAC2 soap_set_sent_logfile(struct soap*, const char*);
  2293. SOAP_FMAC1 void SOAP_FMAC2 soap_set_test_logfile(struct soap*, const char*);
  2294. SOAP_FMAC1 void SOAP_FMAC2 soap_close_logfiles(struct soap*);
  2295. SOAP_FMAC1 void SOAP_FMAC2 soap_open_logfile(struct soap*, int);
  2296. /* */
  2297. SOAP_FMAC1 const char* SOAP_FMAC2 soap_value(struct soap*);
  2298. SOAP_FMAC1 int SOAP_FMAC2 soap_match_tag(struct soap*, const char*, const char *);
  2299. SOAP_FMAC1 int SOAP_FMAC2 soap_match_array(struct soap*, const char*);
  2300. SOAP_FMAC1 int SOAP_FMAC2 soap_element(struct soap*, const char*, int, const char*);
  2301. SOAP_FMAC1 int SOAP_FMAC2 soap_element_begin_out(struct soap*, const char *tag, int id, const char *type);
  2302. SOAP_FMAC1 int SOAP_FMAC2 soap_array_begin_out(struct soap*, const char *tag, int id, const char *type, const char *offset);
  2303. SOAP_FMAC1 int SOAP_FMAC2 soap_element_ref(struct soap*, const char *tag, int id, int href);
  2304. SOAP_FMAC1 int SOAP_FMAC2 soap_element_href(struct soap*, const char *tag, int id, const char *ref, const char *val);
  2305. SOAP_FMAC1 int SOAP_FMAC2 soap_element_null(struct soap*, const char *tag, int id, const char *type);
  2306. SOAP_FMAC1 int SOAP_FMAC2 soap_element_nil(struct soap*, const char *tag);
  2307. SOAP_FMAC1 int SOAP_FMAC2 soap_element_id(struct soap*, const char *tag, int id, const void *p, const struct soap_array *a, int d, const char *type, int n);
  2308. SOAP_FMAC1 int SOAP_FMAC2 soap_element_result(struct soap*, const char *tag);
  2309. SOAP_FMAC1 void SOAP_FMAC2 soap_check_result(struct soap*, const char *tag);
  2310. SOAP_FMAC1 int SOAP_FMAC2 soap_element_end_out(struct soap*, const char *tag);
  2311. SOAP_FMAC1 int SOAP_FMAC2 soap_element_start_end_out(struct soap*, const char *tag);
  2312. SOAP_FMAC1 int SOAP_FMAC2 soap_attribute(struct soap*, const char*, const char*);
  2313. SOAP_FMAC1 int SOAP_FMAC2 soap_element_begin_in(struct soap*, const char *tag, int nillable, const char *type);
  2314. SOAP_FMAC1 int SOAP_FMAC2 soap_element_end_in(struct soap*, const char *tag);
  2315. SOAP_FMAC1 int SOAP_FMAC2 soap_peek_element(struct soap*);
  2316. SOAP_FMAC1 void SOAP_FMAC2 soap_retry(struct soap*);
  2317. SOAP_FMAC1 void SOAP_FMAC2 soap_revert(struct soap*);
  2318. SOAP_FMAC1 char* SOAP_FMAC2 soap_strdup(struct soap*, const char*);
  2319. SOAP_FMAC1 wchar_t* SOAP_FMAC2 soap_wstrdup(struct soap*, const wchar_t*);
  2320. SOAP_FMAC1 const char * SOAP_FMAC2 soap_tagsearch(const char *big, const char *little);
  2321. SOAP_FMAC1 int SOAP_FMAC2 soap_string_out(struct soap*, const char *s, int flag);
  2322. SOAP_FMAC1 char* SOAP_FMAC2 soap_string_in(struct soap*, int, long, long);
  2323. #ifndef WITH_LEANER
  2324. SOAP_FMAC1 int SOAP_FMAC2 soap_wstring_out(struct soap*, const wchar_t *s, int flag);
  2325. SOAP_FMAC1 wchar_t* SOAP_FMAC2 soap_wstring_in(struct soap*, int, long, long);
  2326. #endif
  2327. SOAP_FMAC1 int SOAP_FMAC2 soap_match_namespace(struct soap*, const char *, const char*, size_t n1, size_t n2);
  2328. SOAP_FMAC1 void SOAP_FMAC2 soap_set_version(struct soap*, short);
  2329. SOAP_FMAC1 int SOAP_FMAC2 soap_set_namespaces(struct soap*, const struct Namespace*);
  2330. SOAP_FMAC1 void SOAP_FMAC2 soap_set_local_namespaces(struct soap*);
  2331. SOAP_FMAC1 void SOAP_FMAC2 soap_pop_namespace(struct soap*);
  2332. SOAP_FMAC1 struct soap_nlist* SOAP_FMAC2 soap_push_namespace(struct soap*, const char *,const char *);
  2333. SOAP_FMAC1 const char* SOAP_FMAC2 soap_current_namespace(struct soap *soap, const char *tag);
  2334. SOAP_FMAC1 struct soap_nlist* SOAP_FMAC2 soap_lookup_ns(struct soap *soap, const char *tag, size_t n);
  2335. SOAP_FMAC1 int SOAP_FMAC2 soap_store_lab(struct soap*, const char*, size_t);
  2336. SOAP_FMAC1 int SOAP_FMAC2 soap_append_lab(struct soap*, const char*, size_t);
  2337. SOAP_FMAC1 struct soap_blist* SOAP_FMAC2 soap_new_block(struct soap*);
  2338. SOAP_FMAC1 void* SOAP_FMAC2 soap_push_block(struct soap*, struct soap_blist*, size_t);
  2339. SOAP_FMAC1 void SOAP_FMAC2 soap_pop_block(struct soap*, struct soap_blist*);
  2340. SOAP_FMAC1 size_t SOAP_FMAC2 soap_size_block(struct soap*, struct soap_blist*, size_t);
  2341. SOAP_FMAC1 char* SOAP_FMAC2 soap_first_block(struct soap*, struct soap_blist*);
  2342. SOAP_FMAC1 char* SOAP_FMAC2 soap_next_block(struct soap*, struct soap_blist*);
  2343. SOAP_FMAC1 size_t SOAP_FMAC2 soap_block_size(struct soap*, struct soap_blist*);
  2344. SOAP_FMAC1 char* SOAP_FMAC2 soap_save_block(struct soap*, struct soap_blist*, char*, int);
  2345. SOAP_FMAC1 void SOAP_FMAC2 soap_end_block(struct soap*, struct soap_blist*);
  2346. SOAP_FMAC1 void SOAP_FMAC2 soap_update_pointers(struct soap *soap, char *start, char *end, char *p1, char *p2);
  2347. SOAP_FMAC1 int SOAP_FMAC2 soap_envelope_begin_out(struct soap*);
  2348. SOAP_FMAC1 int SOAP_FMAC2 soap_envelope_end_out(struct soap*);
  2349. SOAP_FMAC1 char * SOAP_FMAC2 soap_get_http_body(struct soap*, size_t *len);
  2350. SOAP_FMAC1 int SOAP_FMAC2 soap_envelope_begin_in(struct soap*);
  2351. SOAP_FMAC1 int SOAP_FMAC2 soap_envelope_end_in(struct soap*);
  2352. SOAP_FMAC1 int SOAP_FMAC2 soap_body_begin_out(struct soap*);
  2353. SOAP_FMAC1 int SOAP_FMAC2 soap_body_end_out(struct soap*);
  2354. SOAP_FMAC1 int SOAP_FMAC2 soap_body_begin_in(struct soap*);
  2355. SOAP_FMAC1 int SOAP_FMAC2 soap_body_end_in(struct soap*);
  2356. SOAP_FMAC1 int SOAP_FMAC2 soap_recv_header(struct soap*);
  2357. SOAP_FMAC1 int SOAP_FMAC2 soap_response(struct soap*, int);
  2358. SOAP_FMAC1 int SOAP_FMAC2 soap_send_empty_response(struct soap*, int status);
  2359. SOAP_FMAC1 int SOAP_FMAC2 soap_recv_empty_response(struct soap*);
  2360. SOAP_FMAC1 int SOAP_FMAC2 soap_send_fault(struct soap*);
  2361. SOAP_FMAC1 int SOAP_FMAC2 soap_recv_fault(struct soap*, int check);
  2362. #ifndef WITH_NOSTDLIB
  2363. SOAP_FMAC1 void SOAP_FMAC2 soap_print_fault(struct soap*, FILE*);
  2364. SOAP_FMAC1 void SOAP_FMAC2 soap_print_fault_location(struct soap*, FILE*);
  2365. # ifndef WITH_LEAN
  2366. # ifndef WITH_COMPAT
  2367. # ifdef __cplusplus
  2368. SOAP_FMAC1 void SOAP_FMAC2 soap_stream_fault(struct soap*, std::ostream&);
  2369. # endif
  2370. # endif
  2371. SOAP_FMAC1 char* SOAP_FMAC2 soap_sprint_fault(struct soap*, char*, size_t);
  2372. # endif
  2373. #endif
  2374. SOAP_FMAC1 int SOAP_FMAC2 soap_s2byte(struct soap*, const char*, char*);
  2375. SOAP_FMAC1 int SOAP_FMAC2 soap_s2short(struct soap*, const char*, short*);
  2376. SOAP_FMAC1 int SOAP_FMAC2 soap_s2int(struct soap*, const char*, int*);
  2377. SOAP_FMAC1 int SOAP_FMAC2 soap_s2long(struct soap*, const char*, long*);
  2378. SOAP_FMAC1 int SOAP_FMAC2 soap_s2LONG64(struct soap*, const char*, LONG64*);
  2379. SOAP_FMAC1 int SOAP_FMAC2 soap_s2float(struct soap*, const char*, float*);
  2380. SOAP_FMAC1 int SOAP_FMAC2 soap_s2double(struct soap*, const char*, double*);
  2381. SOAP_FMAC1 int SOAP_FMAC2 soap_s2unsignedByte(struct soap*, const char*, unsigned char*);
  2382. SOAP_FMAC1 int SOAP_FMAC2 soap_s2unsignedShort(struct soap*, const char*, unsigned short*);
  2383. SOAP_FMAC1 int SOAP_FMAC2 soap_s2unsignedInt(struct soap*, const char*, unsigned int*);
  2384. SOAP_FMAC1 int SOAP_FMAC2 soap_s2unsignedLong(struct soap*, const char*, unsigned long*);
  2385. SOAP_FMAC1 int SOAP_FMAC2 soap_s2ULONG64(struct soap*, const char*, ULONG64*);
  2386. SOAP_FMAC1 int SOAP_FMAC2 soap_s2string(struct soap*, const char*, char**, long minlen, long maxlen);
  2387. SOAP_FMAC1 int SOAP_FMAC2 soap_s2QName(struct soap*, const char*, char**, long minlen, long maxlen);
  2388. #ifndef WITH_LEAN
  2389. SOAP_FMAC1 int SOAP_FMAC2 soap_s2wchar(struct soap*, const char*, wchar_t**, long minlen, long maxlen);
  2390. SOAP_FMAC1 int SOAP_FMAC2 soap_s2dateTime(struct soap*, const char*, time_t*);
  2391. SOAP_FMAC1 char* SOAP_FMAC2 soap_s2base64(struct soap*, const unsigned char*, char*, int);
  2392. SOAP_FMAC1 char* SOAP_FMAC2 soap_s2hex(struct soap*, const unsigned char*, char*, int);
  2393. #endif
  2394. SOAP_FMAC1 const char* SOAP_FMAC2 soap_byte2s(struct soap*, char);
  2395. SOAP_FMAC1 const char* SOAP_FMAC2 soap_short2s(struct soap*, short);
  2396. SOAP_FMAC1 const char* SOAP_FMAC2 soap_int2s(struct soap*, int);
  2397. SOAP_FMAC1 const char* SOAP_FMAC2 soap_long2s(struct soap*, long);
  2398. SOAP_FMAC1 const char* SOAP_FMAC2 soap_LONG642s(struct soap*, LONG64);
  2399. SOAP_FMAC1 const char* SOAP_FMAC2 soap_float2s(struct soap*, float);
  2400. SOAP_FMAC1 const char* SOAP_FMAC2 soap_double2s(struct soap*, double);
  2401. SOAP_FMAC1 const char* SOAP_FMAC2 soap_unsignedByte2s(struct soap*, unsigned char);
  2402. SOAP_FMAC1 const char* SOAP_FMAC2 soap_unsignedShort2s(struct soap*, unsigned short);
  2403. SOAP_FMAC1 const char* SOAP_FMAC2 soap_unsignedInt2s(struct soap*, unsigned int);
  2404. SOAP_FMAC1 const char* SOAP_FMAC2 soap_unsignedLong2s(struct soap*, unsigned long);
  2405. SOAP_FMAC1 const char* SOAP_FMAC2 soap_ULONG642s(struct soap*, ULONG64);
  2406. SOAP_FMAC1 const char* SOAP_FMAC2 soap_QName2s(struct soap*, const char*);
  2407. #ifndef WITH_LEAN
  2408. SOAP_FMAC1 const char* SOAP_FMAC2 soap_wchar2s(struct soap*, const wchar_t*);
  2409. SOAP_FMAC1 const char* SOAP_FMAC2 soap_dateTime2s(struct soap*, time_t);
  2410. SOAP_FMAC1 const char* SOAP_FMAC2 soap_base642s(struct soap*, const char*, char*, size_t, int*);
  2411. SOAP_FMAC1 const char* SOAP_FMAC2 soap_hex2s(struct soap*, const char*, char*, size_t, int*);
  2412. #endif
  2413. SOAP_FMAC1 int* SOAP_FMAC2 soap_inint(struct soap*, const char *tag, int *p, const char *, int);
  2414. SOAP_FMAC1 char* SOAP_FMAC2 soap_inbyte(struct soap*, const char *tag, char *p, const char *, int);
  2415. SOAP_FMAC1 long* SOAP_FMAC2 soap_inlong(struct soap*, const char *tag, long *p, const char *, int);
  2416. SOAP_FMAC1 LONG64* SOAP_FMAC2 soap_inLONG64(struct soap*, const char *tag, LONG64 *p, const char *, int);
  2417. SOAP_FMAC1 short* SOAP_FMAC2 soap_inshort(struct soap*, const char *tag, short *p, const char *, int);
  2418. SOAP_FMAC1 float* SOAP_FMAC2 soap_infloat(struct soap*, const char *tag, float *p, const char *, int);
  2419. SOAP_FMAC1 double* SOAP_FMAC2 soap_indouble(struct soap*, const char *tag, double *p, const char *, int);
  2420. SOAP_FMAC1 unsigned char* SOAP_FMAC2 soap_inunsignedByte(struct soap*, const char *tag, unsigned char *p, const char *, int);
  2421. SOAP_FMAC1 unsigned short* SOAP_FMAC2 soap_inunsignedShort(struct soap*, const char *tag, unsigned short *p, const char *, int);
  2422. SOAP_FMAC1 unsigned int* SOAP_FMAC2 soap_inunsignedInt(struct soap*, const char *tag, unsigned int *p, const char *, int);
  2423. SOAP_FMAC1 unsigned long* SOAP_FMAC2 soap_inunsignedLong(struct soap*, const char *tag, unsigned long *p, const char *, int);
  2424. SOAP_FMAC1 ULONG64* SOAP_FMAC2 soap_inULONG64(struct soap*, const char *tag, ULONG64 *p, const char *, int);
  2425. SOAP_FMAC1 char** SOAP_FMAC2 soap_instring(struct soap*, const char *tag, char **p, const char *, int, int, long, long);
  2426. SOAP_FMAC1 char** SOAP_FMAC2 soap_inliteral(struct soap*, const char *tag, char **p);
  2427. #ifndef WITH_LEAN
  2428. SOAP_FMAC1 time_t* SOAP_FMAC2 soap_indateTime(struct soap*, const char *tag, time_t *p, const char *, int);
  2429. SOAP_FMAC1 time_t SOAP_FMAC2 soap_timegm(struct tm*);
  2430. #endif
  2431. #ifndef WITH_LEANER
  2432. SOAP_FMAC1 wchar_t** SOAP_FMAC2 soap_inwstring(struct soap*, const char *tag, wchar_t **p, const char *, int, long, long);
  2433. SOAP_FMAC1 wchar_t** SOAP_FMAC2 soap_inwliteral(struct soap*, const char *tag, wchar_t **p);
  2434. #endif
  2435. SOAP_FMAC1 int SOAP_FMAC2 soap_outbyte(struct soap*, const char *tag, int id, const char *p, const char *, int);
  2436. SOAP_FMAC1 int SOAP_FMAC2 soap_outshort(struct soap*, const char *tag, int id, const short *p, const char *, int);
  2437. SOAP_FMAC1 int SOAP_FMAC2 soap_outint(struct soap*, const char *tag, int id, const int *p, const char *, int);
  2438. SOAP_FMAC1 int SOAP_FMAC2 soap_outlong(struct soap*, const char *tag, int id, const long *p, const char *, int);
  2439. SOAP_FMAC1 int SOAP_FMAC2 soap_outLONG64(struct soap*, const char *tag, int id, const LONG64 *p, const char *, int);
  2440. SOAP_FMAC1 int SOAP_FMAC2 soap_outfloat(struct soap*, const char *tag, int id, const float *p, const char *, int);
  2441. SOAP_FMAC1 int SOAP_FMAC2 soap_outdouble(struct soap*, const char *tag, int id, const double *p, const char *, int);
  2442. SOAP_FMAC1 int SOAP_FMAC2 soap_outunsignedByte(struct soap*, const char *tag, int id, const unsigned char *p, const char *, int);
  2443. SOAP_FMAC1 int SOAP_FMAC2 soap_outunsignedShort(struct soap*, const char *tag, int id, const unsigned short *p, const char *, int);
  2444. SOAP_FMAC1 int SOAP_FMAC2 soap_outunsignedInt(struct soap*, const char *tag, int id, const unsigned int *p, const char *, int);
  2445. SOAP_FMAC1 int SOAP_FMAC2 soap_outunsignedLong(struct soap*, const char *tag, int id, const unsigned long *p, const char *, int);
  2446. SOAP_FMAC1 int SOAP_FMAC2 soap_outULONG64(struct soap*, const char *tag, int id, const ULONG64 *p, const char *, int);
  2447. SOAP_FMAC1 int SOAP_FMAC2 soap_outstring(struct soap*, const char *tag, int id, char *const*p, const char *, int);
  2448. SOAP_FMAC1 int SOAP_FMAC2 soap_outliteral(struct soap*, const char *tag, char *const*p, const char *type);
  2449. #ifndef WITH_LEAN
  2450. SOAP_FMAC1 int SOAP_FMAC2 soap_outdateTime(struct soap*, const char *tag, int id, const time_t *p, const char *, int);
  2451. #endif
  2452. #ifndef WITH_LEANER
  2453. SOAP_FMAC1 int SOAP_FMAC2 soap_outwstring(struct soap*, const char *tag, int id, wchar_t *const*p, const char *, int);
  2454. SOAP_FMAC1 int SOAP_FMAC2 soap_outwliteral(struct soap*, const char *tag, wchar_t *const*p, const char *type);
  2455. #endif
  2456. #ifndef WITH_LEANER
  2457. SOAP_FMAC1 int SOAP_FMAC2 soap_attachment(struct soap *, const char*, int, const void*, const struct soap_array*, const char*, const char*, const char*, int, const char*, int);
  2458. SOAP_FMAC1 int SOAP_FMAC2 soap_move(struct soap*, size_t);
  2459. SOAP_FMAC1 size_t SOAP_FMAC2 soap_tell(struct soap*);
  2460. SOAP_FMAC1 char* SOAP_FMAC2 soap_dime_option(struct soap*, unsigned short, const char*);
  2461. SOAP_FMAC1 int SOAP_FMAC2 soap_getdimehdr(struct soap*);
  2462. SOAP_FMAC1 int SOAP_FMAC2 soap_getdime(struct soap*);
  2463. SOAP_FMAC1 int SOAP_FMAC2 soap_putdimehdr(struct soap*);
  2464. SOAP_FMAC1 int SOAP_FMAC2 soap_putdime(struct soap*);
  2465. SOAP_FMAC1 int SOAP_FMAC2 soap_getmimehdr(struct soap*);
  2466. SOAP_FMAC1 int SOAP_FMAC2 soap_getmime(struct soap*);
  2467. SOAP_FMAC1 int SOAP_FMAC2 soap_putmimehdr(struct soap*, struct soap_multipart*);
  2468. SOAP_FMAC1 int SOAP_FMAC2 soap_putmime(struct soap*);
  2469. SOAP_FMAC1 void SOAP_FMAC2 soap_set_dime(struct soap*);
  2470. SOAP_FMAC1 void SOAP_FMAC2 soap_set_mime(struct soap*, const char *boundary, const char *start);
  2471. SOAP_FMAC1 void SOAP_FMAC2 soap_clr_dime(struct soap*);
  2472. SOAP_FMAC1 void SOAP_FMAC2 soap_clr_mime(struct soap*);
  2473. SOAP_FMAC1 int SOAP_FMAC2 soap_set_dime_attachment(struct soap*, char *ptr, size_t size, const char *type, const char *id, unsigned short optype, const char *option);
  2474. SOAP_FMAC1 int SOAP_FMAC2 soap_set_mime_attachment(struct soap*, char *ptr, size_t size, enum soap_mime_encoding encoding, const char *type, const char *id, const char *location, const char *description);
  2475. SOAP_FMAC1 void SOAP_FMAC2 soap_post_check_mime_attachments(struct soap *soap);
  2476. SOAP_FMAC1 int SOAP_FMAC2 soap_check_mime_attachments(struct soap *soap);
  2477. SOAP_FMAC1 struct soap_multipart* SOAP_FMAC2 soap_get_mime_attachment(struct soap *soap, void *handle);
  2478. SOAP_FMAC1 int SOAP_FMAC2 soap_match_cid(struct soap*, const char*, const char*);
  2479. #endif
  2480. SOAP_FMAC1 int SOAP_FMAC2 soap_register_plugin_arg(struct soap*, int (*fcreate)(struct soap*, struct soap_plugin*, void*), void*);
  2481. SOAP_FMAC1 void* SOAP_FMAC2 soap_lookup_plugin(struct soap*, const char*);
  2482. SOAP_FMAC1 const char* SOAP_FMAC2 soap_attr_value(struct soap *soap, const char *name, int flag);
  2483. SOAP_FMAC1 int SOAP_FMAC2 soap_set_attr(struct soap *soap, const char *name, const char *value, int flag);
  2484. SOAP_FMAC1 void SOAP_FMAC2 soap_clr_attr(struct soap *soap);
  2485. SOAP_FMAC1 const char* SOAP_FMAC2 soap_url(struct soap *soap, const char*, const char*);
  2486. SOAP_FMAC1 size_t SOAP_FMAC2 soap_encode_url(const char*, char*, size_t);
  2487. SOAP_FMAC1 const char* SOAP_FMAC2 soap_encode_url_string(struct soap*, const char*);
  2488. #ifdef WITH_COOKIES
  2489. SOAP_FMAC1 void SOAP_FMAC2 soap_getcookies(struct soap *soap, const char *val);
  2490. SOAP_FMAC1 extern struct soap_cookie* SOAP_FMAC2 soap_set_cookie(struct soap*, const char*, const char*, const char*, const char*);
  2491. SOAP_FMAC1 extern struct soap_cookie* SOAP_FMAC2 soap_cookie(struct soap*, const char*, const char*, const char*);
  2492. SOAP_FMAC1 extern char* SOAP_FMAC2 soap_cookie_value(struct soap*, const char*, const char*, const char*);
  2493. SOAP_FMAC1 extern char* SOAP_FMAC2 soap_env_cookie_value(struct soap*, const char*, const char*, const char*);
  2494. SOAP_FMAC1 extern time_t SOAP_FMAC2 soap_cookie_expire(struct soap*, const char*, const char*, const char*);
  2495. SOAP_FMAC1 extern int SOAP_FMAC2 soap_set_cookie_expire(struct soap*, const char*, long, const char*, const char*);
  2496. SOAP_FMAC1 extern int SOAP_FMAC2 soap_set_cookie_session(struct soap*, const char*, const char*, const char*);
  2497. SOAP_FMAC1 extern int SOAP_FMAC2 soap_clr_cookie_session(struct soap*, const char*, const char*, const char*);
  2498. SOAP_FMAC1 extern void SOAP_FMAC2 soap_clr_cookie(struct soap*, const char*, const char*, const char*);
  2499. SOAP_FMAC1 extern int SOAP_FMAC2 soap_getenv_cookies(struct soap*);
  2500. SOAP_FMAC1 extern struct soap_cookie* SOAP_FMAC2 soap_copy_cookies(struct soap*, const struct soap*);
  2501. SOAP_FMAC1 extern void SOAP_FMAC2 soap_free_cookies(struct soap*);
  2502. SOAP_FMAC1 int SOAP_FMAC2 soap_putsetcookies(struct soap *soap);
  2503. SOAP_FMAC1 int SOAP_FMAC2 soap_putcookies(struct soap *soap, const char *domain, const char *path, int secure);
  2504. #endif
  2505. #ifdef __cplusplus
  2506. } /* extern "C" */
  2507. #endif
  2508. #endif /* STDSOAP_H */