SoupSession
Object Hierarchy:
E.SoupSession
E.SoupSession
E.SoupSession
Soup.Session
Soup.Session
Soup.Session->E.SoupSession
GLib.Object
GLib.Object
GLib.Object->Soup.Session
Description:
[ CCode ( type_id = "e_soup_session_get_type ()" ) ] [ Version ( since = "3.26" ) ]public class SoupSession : Session
Contains only private data that should be read and manipulated using the functions below.
Content:
Properties:
Static methods:
public static Quark error_quark ()
public static unowned ByteArray ? util_get_message_bytes (Message message)
Returns bytes read from the message response, when the message send
failed.
public static Uri ? util_normalize_uri_path (Uri uri)
Normalizes the path of the uri
, aka encodes characters,
which should be encoded, if needed.
public static InputStream ? util_ref_message_request_body (Message message, out ssize_t out_length)
public static void util_set_message_request_body (Message message, string ? content_type, InputStream input_stream, ssize_t length)
Sets the request body of the message
from the
input_stream
of the length
, with optional content_type
.
public static void util_set_message_request_body_from_data (Message message, bool create_copy, string ? content_type, void * data, ssize_t length, DestroyNotify ? free_func)
Sets the request body of the message
from the data
of the length
, with optional content_type
.
public static unowned string util_status_to_string (uint status_code, string ? reason_phrase)
Returns the reason_phrase
, if it's non-%NULL and
non-empty, a static string corresponding to status_code
.
Creation methods:
Methods:
public bool check_result (Message message, void * read_bytes, size_t bytes_length) throws Error
Checks result of the message
and sets the error
if it failed.
public NamedParameters ? dup_credentials ()
public bool get_authentication_requires_credentials ()
public LoggerLogLevel get_log_level ()
public unowned Source ? get_source ()
Returns an Source associated
with the this , if such was set in the creation time.
public bool get_ssl_error_details (out string out_certificate_pem, out TlsCertificateFlags out_certificate_errors)
Populates out_certificate_pem
and
out_certificate_errors
with the last values returned on BAD_CERTIFICATE error.
public void handle_authentication_failure (NamedParameters ? credentials, Error op_error, out SourceAuthenticationResult out_auth_result, out string out_certificate_pem, out TlsCertificateFlags out_certificate_errors) throws Error
Handles authentication failure and sets appropriate value to the
out_auth_result
for the provided op_error
and used credentials
.
public Message new_message (string method, string uri_string) throws Error
Creates a new Message , similar to
Message , but also presets request headers with "User-Agent" to be "Evolution/version" and with
"Connection" to be "close".
public Message new_message_from_uri (string method, Uri uri) throws Error
Creates a new Message , similar to
Message.from_uri , but also presets request headers with "User-Agent" to be "Evolution/version"
and with "Connection" to be "close".
public void * prepare_message_send_sync (Message message, Cancellable ? cancellable = null ) throws Error
Prepares the message
to be a sent asynchronously with
send_message .
public async InputStream ? send_message (Message message, int io_priority, void * prepare_data, Cancellable ? cancellable, out string ? out_certificate_pem, out TlsCertificateFlags out_certificate_errors) throws Error
Asynchronously sends the message
.
public ByteArray send_message_simple_sync (Message message, Cancellable ? cancellable = null ) throws Error
Similar to
send_message_sync , except it reads whole response content into
memory and returns it as a ByteArray .
public InputStream send_message_sync (Message message, Cancellable ? cancellable = null ) throws Error
Synchronously sends prepared message and returns
InputStream that can be used to read its contents.
public void set_credentials (NamedParameters ? credentials)
Sets credentials to use for connection.
public void setup_logging (string ? logging_level)
Setups logging for the this .
Inherited Members:
All known members inherited from class Soup.Session
abort
accept_language
accept_language_auto
add_feature
add_feature_by_type
get_accept_language
get_accept_language_auto
get_async_result_message
get_feature
get_feature_for_message
get_idle_timeout
get_local_address
get_max_conns
get_max_conns_per_host
get_proxy_resolver
get_remote_connectable
get_timeout
get_tls_database
get_tls_interaction
get_user_agent
has_feature
idle_timeout
local_address
max_conns
max_conns_per_host
preconnect_async
proxy_resolver
remote_connectable
remove_feature
remove_feature_by_type
request_queued
request_unqueued
send
send_and_read
send_and_read_async
send_async
set_accept_language
set_accept_language_auto
set_idle_timeout
set_proxy_resolver
set_timeout
set_tls_database
set_tls_interaction
set_user_agent
timeout
tls_database
tls_interaction
user_agent
websocket_connect_async
All known members inherited from class GLib.Object
@get
@new
@ref
@set
add_toggle_ref
add_weak_pointer
bind_property
connect
constructed
disconnect
dispose
dup_data
dup_qdata
force_floating
freeze_notify
get_class
get_data
get_property
get_qdata
get_type
getv
interface_find_property
interface_install_property
interface_list_properties
is_floating
new_valist
new_with_properties
newv
notify
notify_property
ref_count
ref_sink
remove_toggle_ref
remove_weak_pointer
replace_data
replace_qdata
set_data
set_data_full
set_property
set_qdata
set_qdata_full
set_valist
setv
steal_data
steal_qdata
thaw_notify
unref
watch_closure
weak_ref
weak_unref