Main Page | File List | File Members

Transport.h

Go to the documentation of this file.
00001 /* -*- mode: c++; -*-
00002  *-----------------------------------------------------------------------------
00003  * $RCSfile: Transport.h,v $
00004  *
00005  * See Copyright for the status of this software.
00006  *
00007  * The OpenSOAP Project
00008  * http://opensoap.jp/
00009  *-----------------------------------------------------------------------------
00010  */
00011 #ifndef OpenSOAP_Transport_H
00012 #define OpenSOAP_Transport_H
00013 
00014 #include <OpenSOAP/ByteArray.h>
00015 #include <OpenSOAP/Envelope.h>
00016 #include <OpenSOAP/Stream.h>
00017 
00024 #ifdef __cplusplus
00025 extern "C" {
00026 #endif /* __cplusplus */
00027 
00032     typedef struct tagOpenSOAPTransport OpenSOAPTransport;
00033 
00038     typedef OpenSOAPTransport    *OpenSOAPTransportPtr;
00039 
00048     int
00049     OPENSOAP_API
00050     OpenSOAPTransportCreate(OpenSOAPTransportPtr * /* [out] */ t);
00051 
00060     int
00061     OPENSOAP_API
00062     OpenSOAPTransportRelease(OpenSOAPTransportPtr /* [in] */ t);
00063 
00074     int
00075     OPENSOAP_API
00076     OpenSOAPTransportSend(OpenSOAPTransportPtr /* [in] */ t,
00077                           OpenSOAPEnvelopePtr /* [in] */ soap_env);
00078 
00089     int
00090     OPENSOAP_API
00091     OpenSOAPTransportReceive(OpenSOAPTransportPtr /* [in] */ t,
00092                              OpenSOAPEnvelopePtr * /* [in, out] */ soap_env);
00093 
00102     int
00103     OPENSOAP_API
00104     OpenSOAPTransportConnect(OpenSOAPTransportPtr /* [in] */ t);
00105 
00114     int
00115     OPENSOAP_API
00116     OpenSOAPTransportDisconnect(OpenSOAPTransportPtr /* [in] */ t);
00117 
00134     int
00135     OPENSOAP_API
00136     OpenSOAPTransportInvokeStream(OpenSOAPTransportPtr /* [in] */ t,
00137                                   OpenSOAPStreamPtr /* [in] */ stream,
00138                                   int /* [in] */ input_size,
00139                                   int * /* [out] */ tp_status);
00140 
00155     int
00156     OPENSOAP_API
00157     OpenSOAPTransportInvokeByteArray(OpenSOAPTransportPtr /* [in] */ t,
00158                                      OpenSOAPByteArrayPtr /* [in] */ request,
00159                                      OpenSOAPByteArrayPtr /* [out] */ response,
00160                                      int * /* [out] */ tp_status);
00161 
00193     int
00194     OPENSOAP_API
00195     OpenSOAPTransportInvoke(OpenSOAPTransportPtr /* [in] */ t,
00196                             OpenSOAPEnvelopePtr /* [in] */ request,
00197                             OpenSOAPEnvelopePtr * /* [in, out] */ response);
00198     
00209     int
00210     OPENSOAP_API
00211     OpenSOAPTransportSetSOAPAction(OpenSOAPTransportPtr /* [in, out] */ t,
00212                                    const char * /* [in] */ soap_action);
00213 
00224     int
00225     OPENSOAP_API
00226     OpenSOAPTransportSetURL(OpenSOAPTransportPtr /* [in, out] */ t,
00227                             const char * /* [in] */ url);
00228 
00241     int
00242     OPENSOAP_API
00243     OpenSOAPTransportSetHeader(OpenSOAPTransportPtr /* [in, out] */ t,
00244                                const char * /* [in] */ header_name,
00245                                const char * /* [in] */ header_value);
00246 
00259     int
00260     OPENSOAP_API
00261     OpenSOAPTransportGetHeader(OpenSOAPTransportPtr /* [in] */ t,
00262                                const char * /* [in] */ header_name,
00263                                char ** /* [out] */ header_value);
00264     
00275     int
00276     OPENSOAP_API
00277     OpenSOAPTransportSetCharset(OpenSOAPTransportPtr /* [out] */ t,
00278                                 const char * /* [in] */ charset);
00279 
00290     int
00291     OPENSOAP_API
00292     OpenSOAPTransportSetContentType(OpenSOAPTransportPtr /* [out] */ t,
00293                                     const char * /* [in] */ content_type);
00294 
00303     int
00304     OPENSOAP_API
00305     OpenSOAPTransportSMTPSetHostname(OpenSOAPTransportPtr /* [in, out] */ s);
00306 
00315     int
00316     OPENSOAP_API
00317     OpenSOAPTransportSMTPSetFrom(OpenSOAPTransportPtr /* [in, out] */ t);
00318 
00327     int
00328     OPENSOAP_API
00329     OpenSOAPTransportSMTPSetTo(OpenSOAPTransportPtr /* [in, out] */ t);
00330 
00343     int
00344     OPENSOAP_API
00345     OpenSOAPTransportSetAuthUserPass(OpenSOAPTransportPtr /* [out] */ t,
00346                                                                          const char * /* [in] */ user,
00347                                                                          const char * /* [in] */ passwd);
00348 
00353 #define OPENSOAP_AUTH_TYPE_BASIC    (1)  /* BASIC */
00354 
00359 #define OPENSOAP_AUTH_TYPE_DIGEST    (2)  /* DIGEST */
00360 
00365 #define OPENSOAP_AUTH_TYPE_ANY (0)
00366 
00383     int
00384     OPENSOAP_API
00385     OpenSOAPTransportSetAuthType(OpenSOAPTransportPtr /* [out] */ t,
00386                                                                  int /* [in] */ auth_type );
00387 
00410     int
00411     OPENSOAP_API
00412     OpenSOAPTransportSetProxy(OpenSOAPTransportPtr /* [out] */ t,
00413                               const char * /* [in] */ host,
00414                               int /* [in] */ port,
00415                               const char * /* [in] */ user,
00416                               const char * /* [in] */ passwd,
00417                               int /* [in] */ auth_type);
00418 
00423 #define OPENSOAP_SSL_VER_SSL2    (1)  /* SSL_V2.0 ONLY */
00424     
00429 #define OPENSOAP_SSL_VER_SSL3    (2)  /* SSL_V3.0 ONLY */
00430     
00435 #define OPENSOAP_SSL_VER_TLS1    (4)  /* TLS_V1.0 ONLY */
00436 
00442 #define OPENSOAP_SSL_VER_ALL (0) /* SSL all version */
00443     
00457     int
00458     OPENSOAP_API
00459     OpenSOAPTransportSetSSLVersion(OpenSOAPTransportPtr /* [out] */ t,
00460                                 int /* [in] */ ssl_version );
00461 
00487     int
00488     OPENSOAP_API
00489     OpenSOAPTransportSetSSLCert(OpenSOAPTransportPtr /* [out] */ t,
00490                                       const char * /* [in] */ ca_file,
00491                                       const char * /* [in] */ ca_dir,
00492                                       const char * /* [in] */ certchain_file,
00493                                       const char * /* [in] */ privkey_file,
00494                                       int /* [in] */ verify_level );
00495 
00496 #ifdef __cplusplus
00497 }
00498 #endif /* __cplusplus */
00499 
00500 #endif /* OpenSOAP_Transport_H */

Generated on Mon Oct 18 18:29:44 2004 for OpenSOAP by doxygen 1.3.6