Msg.Service¶
- Subclasses:
Msg.ContactService
,Msg.DriveService
,Msg.MessageService
,Msg.UserService
Methods¶
- Inherited:
- Structs:
class |
|
class |
|
class |
|
class |
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
---|---|---|---|
w/co |
The authorizer for this service |
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
---|---|---|---|
parent_instance |
r |
Class Details¶
- class Msg.Service(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
- classmethod accept_certificate_cb(msg, tls_cert, tls_errors, session)¶
- Parameters:
msg (
Soup.Message
) –tls_cert (
Gio.TlsCertificate
) –tls_errors (
Gio.TlsCertificateFlags
) –
- Return type:
- classmethod get_next_link(object)¶
- Parameters:
object (
Json.Object
) – aJson.Object
- Returns:
next link or
None
if not available- Return type:
Get next link
- classmethod parse_response(bytes, object)¶
- Parameters:
bytes (
GLib.Bytes
) – input bytes containing response bufferobject (
Json.Object
) – a pointer to the returning root object
- Raises:
- Returns:
- Return type:
Parse response data and check for errors. In case no errors are found, return json root object.
- build_message(method, uri, etag, etag_if_match)¶
- Parameters:
- Returns:
a
Soup.Message
orNone
on error.- Return type:
Construct and checks a
Soup.Message
for transfer
- get_authorizer()¶
- Returns:
- Return type:
Get related authorizer.
- get_session()¶
- Returns:
- Return type:
Get related soup session
- refresh_authorization(cancellable)¶
- Parameters:
cancellable (
Gio.Cancellable
orNone
) –- Raises:
- Return type:
- send(message, cancellable)¶
- Parameters:
message (
Soup.Message
) – aSoup.Message
cancellable (
Gio.Cancellable
orNone
) – aGio.Cancellable
- Raises:
- Returns:
- Return type:
Adds authorizer information to
message
and send it.
- send_and_parse_response(message, object, cancellable)¶
- Parameters:
message (
Soup.Message
) – aSoup.Message
object (
Json.Object
) –cancellable (
Gio.Cancellable
orNone
) – aGio.Cancellable
- Raises:
- Returns:
a
Json.Parser
orNone
on error- Return type:
A combination of
msg_service_send_and_read
andmsg_service_parse_response
- send_and_read(message, cancellable)¶
- Parameters:
message (
Soup.Message
) – aSoup.Message
cancellable (
Gio.Cancellable
orNone
) – aGio.Cancellable
- Raises:
- Returns:
a
GLib.Bytes
orNone
on error.- Return type:
Adds authorizer information to
message
and send it.
Property Details¶
- Msg.Service.props.authorizer¶
- Name:
authorizer
- Type:
- Default Value:
- Flags:
The authorizer for this service