CodePorting.Translator Cs2Cpp
CodePorting.Translator.Cs2Cpp.Framework
System::Web::Services::Protocols::SoapHttpClientProtocol Class Reference

The client proxy services must inherit this class when the SOAP is used. Objects of this class should only be allocated using System::MakeObject() function. Never create instance of this type on stack or using operator new, as it will result in runtime errors and/or assertion faults. Always wrap this class into System::SmartPtr pointer and use this pointer to pass it to functions as argument. More...

#include <soap_http_client_protocol.h>

Inherits System::Web::Services::Protocols::HttpWebClientProtocol.

Public Member Functions

SoapProtocolVersion get_SoapVersion ()
 Gets the SOAP version. More...
 
void set_SoapVersion (SoapProtocolVersion value)
 Sets the SOAP version. More...
 
 SoapHttpClientProtocol ()
 Constructs a new instance. More...
 
void Discover ()
 Binds the current instance to the XML Web service. More...
 
void InitializeSerializers (const System::TypeInfo &serviceType, System::SharedPtr< System::Xml::Serialization::XmlSerializerImplementation > impl, String name)
 Initializes the internal fields. More...
 
- Public Member Functions inherited from System::Web::Services::Protocols::HttpWebClientProtocol
bool get_AllowAutoRedirect ()
 Gets a value that indicates if the client follows server redirects. More...
 
void set_AllowAutoRedirect (bool value)
 Sets a value that indicates if the client follows server redirects. More...
 
System::SharedPtr< Security::Cryptography::X509Certificates::X509CertificateCollectionget_ClientCertificates ()
 Returns the collection of the client certificates. More...
 
System::SharedPtr< System::Net::CookieContainerget_CookieContainer ()
 Gets a container that is used to store cookies. More...
 
void set_CookieContainer (System::SharedPtr< System::Net::CookieContainer > value)
 Sets a container that is used to store cookies. More...
 
bool get_EnableDecompression ()
 Gets a value that indicates if decompression is enabled. More...
 
void set_EnableDecompression (bool value)
 Sets a value that indicates if decompression is enabled. More...
 
System::SharedPtr< Net::IWebProxyget_Proxy ()
 Gets proxy information. More...
 
void set_Proxy (System::SharedPtr< Net::IWebProxy > value)
 Sets proxy information. More...
 
String get_UserAgent ()
 Gets a value of the 'User-Agent' header. More...
 
void set_UserAgent (String value)
 Sets a value of the 'User-Agent' header. More...
 
bool get_UnsafeAuthenticatedConnectionSharing ()
 Gets a value that indicates if the connection sharing is enabled when the client uses NTLM authentication. More...
 
void set_UnsafeAuthenticatedConnectionSharing (bool value)
 Sets a value that indicates if the connection sharing is enabled when the client uses NTLM authentication. More...
 
virtual void CheckForCookies (System::SharedPtr< Net::HttpWebResponse > response)
 Appends cookies from the specified request to the internal cookie container. More...
 
void UnregisterMapping (System::SharedPtr< Object > userState)
 
- Public Member Functions inherited from System::Web::Services::Protocols::WebClientProtocol
System::SharedPtr< Uriget_Uri ()
 Gets the XML Web service URI. More...
 
void set_Uri (System::SharedPtr< Uri > uri)
 Sets the XML Web service URI. More...
 
String get_ConnectionGroupName ()
 Gets the name of the connection group. More...
 
void set_ConnectionGroupName (String value)
 Sets the name of the connection group. More...
 
System::SharedPtr< Net::ICredentialsget_Credentials ()
 Gets the authentication information. More...
 
void set_Credentials (System::SharedPtr< Net::ICredentials > value)
 Sets the authentication information. More...
 
bool get_PreAuthenticate ()
 Gets a value that indicates if pre-authentication is enabled. More...
 
void set_PreAuthenticate (bool value)
 Sets a value that indicates if pre-authentication is enabled. More...
 
System::SharedPtr< Text::Encodingget_RequestEncoding ()
 Gets the encoding that is used to make the client requests. More...
 
void set_RequestEncoding (System::SharedPtr< Text::Encoding > value)
 Sets the encoding that is used to make the client requests. More...
 
int32_t get_Timeout ()
 Gets the timespan to wait before the request times out. More...
 
void set_Timeout (int32_t value)
 Sets the timespan to wait before the request times out. More...
 
String get_Url ()
 Gets the XML Web service URL. More...
 
void set_Url (String value)
 Sets the XML Web service URL. More...
 
bool get_UseDefaultCredentials ()
 Gets a value that indicates if the 'Credential' property is equal to the 'DefaultCredentials' property. More...
 
void set_UseDefaultCredentials (bool value)
 Sets a value that indicates if the 'Credential' property is equal to the 'DefaultCredentials' property. More...
 
virtual void Abort ()
 Cancels the request. More...
 
- Public Member Functions inherited from System::Object
 Object ()
 Creates object. Initializes all internal data structures. More...
 
virtual ~Object ()
 Destroys object. Frees all internal data structures. More...
 
 Object (Object const &x)
 Copy constructor. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More...
 
Objectoperator= (Object const &x)
 Assignment operator. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More...
 
ObjectSharedRefAdded ()
 Increments shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
int SharedRefRemovedSafe ()
 Decrements and returns shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
int RemovedSharedRefs (int count)
 Decreases shared reference count by specified value. More...
 
Detail::SmartPtrCounter * WeakRefAdded ()
 Increments weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
void WeakRefRemoved ()
 Decrements weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
Detail::SmartPtrCounter * GetCounter ()
 Gets reference counter data structure associated with the object. More...
 
int SharedCount () const
 Gets current value of shared reference counter. More...
 
void Lock ()
 Implements C# lock() statement locking. Call directly or use LockContext sentry object. More...
 
void Unlock ()
 Implements C# lock() statement unlocking. Call directly or use LockContext sentry object. More...
 
virtual bool Equals (ptr obj)
 Compares objects using C# Object.Equals semantics. More...
 
virtual int32_t GetHashCode () const
 Analog of C# Object.GetHashCode() method. Enables hashing of custom objects. More...
 
virtual String ToString () const
 Analog of C# Object.ToString() method. Enables converting custom objects to string. More...
 
virtual ptr MemberwiseClone () const
 Analog of C# Object.MemberwiseClone() method. Enables cloning custom types. More...
 
virtual const TypeInfoGetType () const
 Gets actual type of object. Analog of C# System.Object.GetType() call. More...
 
virtual bool Is (const TypeInfo &targetType) const
 Check if object represents an instance of type described by targetType. Analog of C# 'is' operator. More...
 
virtual void SetTemplateWeakPtr (uint32_t argument)
 Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. More...
 
virtual bool FastCast (const Details::FastRttiBase &helper, void **out_ptr) const
 For internal purposes only. More...
 
template<>
bool ReferenceEquals (String const &str, std::nullptr_t)
 Specialization of Object::ReferenceEquals for case of string and nullptr. More...
 
template<>
bool ReferenceEquals (String const &str1, String const &str2)
 Specialization of Object::ReferenceEquals for case of strings. More...
 

Protected Member Functions

System::SharedPtr< IAsyncResultBeginInvoke (String methodName, System::ArrayPtr< System::SharedPtr< Object > > parameters, AsyncCallback callback, System::SharedPtr< Object > asyncState)
 Initiates an asynchronous call. More...
 
System::ArrayPtr< System::SharedPtr< Object > > EndInvoke (System::SharedPtr< IAsyncResult > asyncResult)
 Waits until the specified asynchronous call completes. More...
 
virtual System::SharedPtr< Net::WebRequestGetWebRequest (System::SharedPtr< System::Uri > uri)
 Creates a WebRequest-class instance for the specified URI. More...
 
virtual System::SharedPtr< Xml::XmlReaderGetReaderForMessage (System::SharedPtr< SoapClientMessage > message, int32_t bufferSize)
 Creates an XmlReader-class instance using the specified message. More...
 
virtual System::SharedPtr< Xml::XmlWriterGetWriterForMessage (System::SharedPtr< SoapClientMessage > message, int32_t bufferSize)
 Creates an XmlWriter-class instance using the specified message. More...
 
System::ArrayPtr< System::SharedPtr< Object > > Invoke (String method_name, System::ArrayPtr< System::SharedPtr< Object > > parameters)
 Calls the specified method synchronously. More...
 
void InvokeAsync (String methodName, System::ArrayPtr< System::SharedPtr< Object > > parameters, Threading::SendOrPostCallback callback)
 
void InvokeAsync (String methodName, System::ArrayPtr< System::SharedPtr< Object > > parameters, Threading::SendOrPostCallback callback, System::SharedPtr< Object > userState)
 Calls the specified method asynchronously. More...
 
- Protected Member Functions inherited from System::Web::Services::Protocols::HttpWebClientProtocol
 HttpWebClientProtocol ()
 Constructs a new instance. More...
 
System::SharedPtr< Net::WebRequestGetWebRequest (System::SharedPtr< Uri > uri) override
 Creates a WebRequest-class instance for the specified URI. More...
 
System::SharedPtr< Net::WebResponseGetWebResponse (System::SharedPtr< Net::WebRequest > request) override
 Creates a WebResponse-class instance for the specified request. More...
 
System::SharedPtr< Net::WebResponseGetWebResponse (System::SharedPtr< Net::WebRequest > request, System::SharedPtr< IAsyncResult > result) override
 Creates a WebResponse-class instance for the specified request. More...
 
void CancelAsync (System::SharedPtr< Object > userState)
 
- Protected Member Functions inherited from System::Web::Services::Protocols::WebClientProtocol
 WebClientProtocol ()
 Constructs a new instance. More...
 
virtual System::SharedPtr< Net::WebRequestGetWebRequest (System::SharedPtr< Uri > uri)
 Creates a WebRequest-class instance for the specified URI. More...
 
virtual System::SharedPtr< Net::WebResponseGetWebResponse (System::SharedPtr< Net::WebRequest > request)
 Creates a WebResponse-class instance for the specified request. More...
 
virtual System::SharedPtr< Net::WebResponseGetWebResponse (System::SharedPtr< Net::WebRequest > request, System::SharedPtr< IAsyncResult > result)
 Creates a WebResponse-class instance for the specified request. More...
 

Additional Inherited Members

- Public Types inherited from System::Object
typedef SmartPtr< Objectptr
 Alias for smart pointer type. More...
 
- Static Public Member Functions inherited from System::Object
static bool ReferenceEquals (ptr const &objA, ptr const &objB)
 Compares objects by reference. More...
 
template<typename T >
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, T const &objB)
 Compares objects by reference. More...
 
template<typename T >
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, std::nullptr_t)
 Reference-compares value type object with nullptr. More...
 
template<typename T1 , typename T2 >
static std::enable_if< IsSmartPtr< T1 >::value &&IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 Compares reference type objects in C# style. More...
 
template<typename T1 , typename T2 >
static std::enable_if<!IsSmartPtr< T1 >::value &&!IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 Compares value type objects in C# style. More...
 
static const TypeInfoType ()
 Implements C# typeof(System.Object) construct. More...
 
template<>
bool Equals (float const &objA, float const &objB)
 Emulates C#-style floating point comparison where two NaNs are considered equal even though according to IEC 60559:1989 NaN is not equal to any value, including NaN. More...
 
template<>
bool Equals (double const &objA, double const &objB)
 Emulates C#-style floating point comparison where two NaNs are considered equal even though according to IEC 60559:1989 NaN is not equal to any value, including NaN. More...
 
- Public Attributes inherited from System::Web::Services::Protocols::WebClientProtocol
System::SharedPtr< Uriuri
 The XML Web service URI. More...
 
- Static Protected Member Functions inherited from System::Web::Services::Protocols::WebClientProtocol
static void AddToCache (const TypeInfo &type, System::SharedPtr< Object > value)
 Adds the specified instance of the client protocol handler to the internal cache. More...
 
static System::SharedPtr< ObjectGetFromCache (const TypeInfo &type)
 Gets the client protocol handler from the cache. More...
 

Detailed Description

The client proxy services must inherit this class when the SOAP is used. Objects of this class should only be allocated using System::MakeObject() function. Never create instance of this type on stack or using operator new, as it will result in runtime errors and/or assertion faults. Always wrap this class into System::SmartPtr pointer and use this pointer to pass it to functions as argument.

Constructor & Destructor Documentation

◆ SoapHttpClientProtocol()

System::Web::Services::Protocols::SoapHttpClientProtocol::SoapHttpClientProtocol ( )

Constructs a new instance.

Member Function Documentation

◆ BeginInvoke()

System::SharedPtr< IAsyncResult > System::Web::Services::Protocols::SoapHttpClientProtocol::BeginInvoke ( String  methodName,
System::ArrayPtr< System::SharedPtr< Object > >  parameters,
AsyncCallback  callback,
System::SharedPtr< Object asyncState 
)
protected

Initiates an asynchronous call.

Parameters
methodNameThe method name of the derived class that calls the 'BeginInvoke' method.
parametersA collection of parameters passed to an XML Web service method.
callbackA callback to be called when the operation completes.
asyncStateUser-provided data used to uniquely identify each asynchronous call.
Returns
An IAsyncResult object representing the initiated asynchronous call.

◆ Discover()

void System::Web::Services::Protocols::SoapHttpClientProtocol::Discover ( )

Binds the current instance to the XML Web service.

◆ EndInvoke()

System::ArrayPtr< System::SharedPtr< Object > > System::Web::Services::Protocols::SoapHttpClientProtocol::EndInvoke ( System::SharedPtr< IAsyncResult asyncResult)
protected

Waits until the specified asynchronous call completes.

Parameters
asyncResultAn IAsyncResult object that represents an asynchronous call.
Returns
An array of objects that contains the method result and the output parameters.

◆ get_SoapVersion()

SoapProtocolVersion System::Web::Services::Protocols::SoapHttpClientProtocol::get_SoapVersion ( )

Gets the SOAP version.

Returns
The SOAP version.

◆ GetReaderForMessage()

virtual System::SharedPtr< Xml::XmlReader > System::Web::Services::Protocols::SoapHttpClientProtocol::GetReaderForMessage ( System::SharedPtr< SoapClientMessage message,
int32_t  bufferSize 
)
protectedvirtual

Creates an XmlReader-class instance using the specified message.

Parameters
messageA SoapClientMessage-class instance that is used to initialize an XmlReader-class instance.
bufferSizeThe initial size of the internal buffer.
Returns
A newly created XmlReader-class instance.

◆ GetWebRequest()

virtual System::SharedPtr< Net::WebRequest > System::Web::Services::Protocols::SoapHttpClientProtocol::GetWebRequest ( System::SharedPtr< System::Uri uri)
protectedvirtual

Creates a WebRequest-class instance for the specified URI.

Parameters
uriThe URI that is used to initialize a new WebRequest-class instance.
Returns
A newly created WebRequest-class instance.

◆ GetWriterForMessage()

virtual System::SharedPtr< Xml::XmlWriter > System::Web::Services::Protocols::SoapHttpClientProtocol::GetWriterForMessage ( System::SharedPtr< SoapClientMessage message,
int32_t  bufferSize 
)
protectedvirtual

Creates an XmlWriter-class instance using the specified message.

Parameters
messageA SoapClientMessage-class instance that is used to initialize an XmlWriter-class instance.
bufferSizeThe initial size of the internal buffer.
Returns
A newly created XmlWriter-class instance.

◆ InitializeSerializers()

void System::Web::Services::Protocols::SoapHttpClientProtocol::InitializeSerializers ( const System::TypeInfo serviceType,
System::SharedPtr< System::Xml::Serialization::XmlSerializerImplementation impl,
String  name 
)

Initializes the internal fields.

◆ Invoke()

System::ArrayPtr< System::SharedPtr< Object > > System::Web::Services::Protocols::SoapHttpClientProtocol::Invoke ( String  method_name,
System::ArrayPtr< System::SharedPtr< Object > >  parameters 
)
protected

Calls the specified method synchronously.

Parameters
method_nameThe method name of the XML Web service to call.
parametersA collection of parameters passed to an XML Web service method.
Returns
An array of objects that contains the method result and the output parameters.

◆ InvokeAsync() [1/2]

void System::Web::Services::Protocols::SoapHttpClientProtocol::InvokeAsync ( String  methodName,
System::ArrayPtr< System::SharedPtr< Object > >  parameters,
Threading::SendOrPostCallback  callback 
)
protected

◆ InvokeAsync() [2/2]

void System::Web::Services::Protocols::SoapHttpClientProtocol::InvokeAsync ( String  methodName,
System::ArrayPtr< System::SharedPtr< Object > >  parameters,
Threading::SendOrPostCallback  callback,
System::SharedPtr< Object userState 
)
protected

Calls the specified method asynchronously.

Parameters
methodNameThe method name of the XML Web service to call.
parametersA collection of parameters passed to an XML Web service method.
callbackA callback to be called when the operation completes.
userStateUser-provided data used to uniquely identify each asynchronous call.

◆ set_SoapVersion()

void System::Web::Services::Protocols::SoapHttpClientProtocol::set_SoapVersion ( SoapProtocolVersion  value)

Sets the SOAP version.

Parameters
valueThe value that must be set.