ISOAPTransport::Receive Method

HRESULT Receive([in, out] BSTR * characterEncoding, [out, retval] SAFEARRAY(BYTE) * Envelope);

Once send has been called, the client code can call Receive to retrieve the response to the request. The response is typically in the character encoding that the server returned, however if the server returns a response in a character encoding that's not supported by the Envelope class, then the transport object can transcode the response to one of the supported character encodings.
The case where the transport specification indicates that the transport can override the character encoding indicated in the XML payload [such as HTTP], the transport can set the characterEncoding to the relevant value, the client code should then treat the response that character encoding.
Typically you don't call receive directly, calling ISOAPEnvelope::Parse and passing it a transport object, will call receive and handle the character encoding issues for you.

 

Parameters

characterEncoding
BSTR *, [in, out]: The characterEncoding of the response, if the transport can detect it [e.g. UTF-8]
Envelope
SAFEARRAY(BYTE) *, [out, retval]: An array of bytes representing the response SOAP envelope

 

Return Values

 

Sample Code

dim t
set t= CreateObject("pocketSOAP.HTTPTransport")
t.send "http://example.org/", e.serialize
e.parse t

 

See Also

The ISOAPTransport Interface | 

 

 

Copyright

Copyright © Simon Fell, 2000-2004. All rights reserved.