Session.sendAsync

Asynchronously sends @msg and waits for the beginning of a response. When @callback is called, then either @msg has been sent, and its response headers received, or else an error has occurred. Call soup_session_send_finish() to get a #GInputStream for reading the response body.

See soup_session_send() for more details on the general semantics.

Contrast this method with soup_session_queue_message(), which also asynchronously sends a #SoupMessage, but doesn't invoke its callback until the response has been completely read.

(Note that this method cannot be called on the deprecated #SoupSessionSync subclass, and can only be called on #SoupSessionAsync if you have set the #SoupSession:use-thread-context property.)

class Session
void
sendAsync
(,
Cancellable cancellable
,
GAsyncReadyCallback callback
,
void* userData
)

Parameters

msg Message

a #SoupMessage

cancellable Cancellable

a #GCancellable

callback GAsyncReadyCallback

the callback to invoke

userData void*

data for @callback

Meta

Since

2.42