![]() |
![]() |
![]() |
GNOME Online Accounts Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Implemented Interfaces | Prerequisites | Known Implementations | Properties | Signals |
GoaAccount; struct GoaAccountIface; GDBusInterfaceInfo * goa_account_interface_info (void
); guint goa_account_override_properties (GObjectClass *klass
,guint property_id_begin
); const gchar * goa_account_get_provider_type (GoaAccount *object
); void goa_account_set_provider_type (GoaAccount *object
,const gchar *value
); const gchar * goa_account_get_provider_name (GoaAccount *object
); void goa_account_set_provider_name (GoaAccount *object
,const gchar *value
); const gchar * goa_account_get_provider_icon (GoaAccount *object
); void goa_account_set_provider_icon (GoaAccount *object
,const gchar *value
); const gchar * goa_account_get_id (GoaAccount *object
); void goa_account_set_id (GoaAccount *object
,const gchar *value
); gboolean goa_account_get_attention_needed (GoaAccount *object
); void goa_account_set_attention_needed (GoaAccount *object
,gboolean value
); const gchar * goa_account_get_identity (GoaAccount *object
); void goa_account_set_identity (GoaAccount *object
,const gchar *value
); const gchar * goa_account_get_presentation_identity (GoaAccount *object
); void goa_account_set_presentation_identity (GoaAccount *object
,const gchar *value
); void goa_account_call_ensure_credentials (GoaAccount *proxy
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean goa_account_call_ensure_credentials_finish (GoaAccount *proxy
,gint *out_expires_in
,GAsyncResult *res
,GError **error
); gboolean goa_account_call_ensure_credentials_sync (GoaAccount *proxy
,gint *out_expires_in
,GCancellable *cancellable
,GError **error
); void goa_account_complete_ensure_credentials (GoaAccount *object
,GDBusMethodInvocation *invocation
,gint expires_in
); void goa_account_call_remove (GoaAccount *proxy
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); gboolean goa_account_call_remove_finish (GoaAccount *proxy
,GAsyncResult *res
,GError **error
); gboolean goa_account_call_remove_sync (GoaAccount *proxy
,GCancellable *cancellable
,GError **error
); void goa_account_complete_remove (GoaAccount *object
,GDBusMethodInvocation *invocation
); struct GoaAccountProxy; struct GoaAccountProxyClass; void goa_account_proxy_new (GDBusConnection *connection
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); GoaAccount * goa_account_proxy_new_finish (GAsyncResult *res
,GError **error
); GoaAccount * goa_account_proxy_new_sync (GDBusConnection *connection
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GError **error
); void goa_account_proxy_new_for_bus (GBusType bus_type
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
); GoaAccount * goa_account_proxy_new_for_bus_finish (GAsyncResult *res
,GError **error
); GoaAccount * goa_account_proxy_new_for_bus_sync (GBusType bus_type
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GError **error
); struct GoaAccountSkeleton; struct GoaAccountSkeletonClass; GoaAccount * goa_account_skeleton_new (void
);
GInterface +----GoaAccount
GObject +----GDBusProxy +----GoaAccountProxy
GObject +----GDBusInterfaceSkeleton +----GoaAccountSkeleton
GoaAccountProxy implements GDBusInterface, GInitable, GAsyncInitable and GoaAccount.
GoaAccountSkeleton implements GDBusInterface and GoaAccount.
"attention-needed" gboolean : Read / Write "id" gchar* : Read / Write "identity" gchar* : Read / Write "presentation-identity" gchar* : Read / Write "provider-icon" gchar* : Read / Write "provider-name" gchar* : Read / Write "provider-type" gchar* : Read / Write
This section contains code for working with the org.gnome.OnlineAccounts.Account D-Bus interface in C.
typedef struct _GoaAccount GoaAccount;
Abstract interface type for the D-Bus interface org.gnome.OnlineAccounts.Account.
struct GoaAccountIface { GTypeInterface parent_iface; gboolean (*handle_ensure_credentials) ( GoaAccount *object, GDBusMethodInvocation *invocation); gboolean (*handle_remove) ( GoaAccount *object, GDBusMethodInvocation *invocation); gboolean (*get_attention_needed) (GoaAccount *object); const gchar * (*get_id) (GoaAccount *object); const gchar * (*get_identity) (GoaAccount *object); const gchar * (*get_presentation_identity) (GoaAccount *object); const gchar * (*get_provider_icon) (GoaAccount *object); const gchar * (*get_provider_name) (GoaAccount *object); const gchar * (*get_provider_type) (GoaAccount *object); };
Virtual table for the D-Bus interface org.gnome.OnlineAccounts.Account.
GTypeInterface |
The parent interface. |
Handler for the "handle-ensure-credentials" signal. | |
Handler for the "handle-remove" signal. | |
Getter for the "attention-needed" property. | |
Getter for the "id" property. | |
Getter for the "identity" property. | |
Getter for the "presentation-identity" property. | |
Getter for the "provider-icon" property. | |
Getter for the "provider-name" property. | |
Getter for the "provider-type" property. |
GDBusInterfaceInfo * goa_account_interface_info (void
);
Gets a machine-readable description of the org.gnome.OnlineAccounts.Account D-Bus interface.
Returns : |
A GDBusInterfaceInfo. Do not free. [transfer none] |
guint goa_account_override_properties (GObjectClass *klass
,guint property_id_begin
);
Overrides all GObject properties in the GoaAccount interface for a concrete class. The properties are overridden in the order they are defined.
|
The class structure for a GObject-derived class. |
|
The property id to assign to the first overridden property. |
Returns : |
The last property id. |
const gchar * goa_account_get_provider_type (GoaAccount *object
);
Gets the value of the "ProviderType" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_provider_type()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_provider_type (GoaAccount *object
,const gchar *value
);
Sets the "ProviderType" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
const gchar * goa_account_get_provider_name (GoaAccount *object
);
Gets the value of the "ProviderName" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_provider_name()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_provider_name (GoaAccount *object
,const gchar *value
);
Sets the "ProviderName" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
const gchar * goa_account_get_provider_icon (GoaAccount *object
);
Gets the value of the "ProviderIcon" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_provider_icon()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_provider_icon (GoaAccount *object
,const gchar *value
);
Sets the "ProviderIcon" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
const gchar * goa_account_get_id (GoaAccount *object
);
Gets the value of the "Id" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_id()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_id (GoaAccount *object
,const gchar *value
);
Sets the "Id" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
gboolean goa_account_get_attention_needed (GoaAccount *object
);
Gets the value of the "AttentionNeeded" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
|
A GoaAccount. |
Returns : |
The property value. |
void goa_account_set_attention_needed (GoaAccount *object
,gboolean value
);
Sets the "AttentionNeeded" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
const gchar * goa_account_get_identity (GoaAccount *object
);
Gets the value of the "Identity" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_identity()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_identity (GoaAccount *object
,const gchar *value
);
Sets the "Identity" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
const gchar * goa_account_get_presentation_identity
(GoaAccount *object
);
Gets the value of the "PresentationIdentity" D-Bus property.
Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
object
was constructed. Use goa_account_dup_presentation_identity()
if on another thread.
|
A GoaAccount. |
Returns : |
The property value or NULL if the property is not set. Do not free the returned value, it belongs to object . [transfer none]
|
void goa_account_set_presentation_identity (GoaAccount *object
,const gchar *value
);
Sets the "PresentationIdentity" D-Bus property to value
.
Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
|
A GoaAccount. |
|
The value to set. |
void goa_account_call_ensure_credentials (GoaAccount *proxy
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Asynchronously invokes the EnsureCredentials()
D-Bus method on proxy
.
When the operation is finished, callback
will be invoked in the thread-default main loop of the thread you are calling this method from.
You can then call goa_account_call_ensure_credentials_finish()
to get the result of the operation.
See goa_account_call_ensure_credentials_sync()
for the synchronous, blocking version of this method.
|
A GoaAccountProxy. |
|
A GCancellable or NULL . [allow-none]
|
|
A GAsyncReadyCallback to call when the request is satisfied or NULL . |
|
User data to pass to callback . |
gboolean goa_account_call_ensure_credentials_finish (GoaAccount *proxy
,gint *out_expires_in
,GAsyncResult *res
,GError **error
);
Finishes an operation started with goa_account_call_ensure_credentials()
.
|
A GoaAccountProxy. |
|
Return location for return parameter or NULL to ignore. [out]
|
|
The GAsyncResult obtained from the GAsyncReadyCallback passed to goa_account_call_ensure_credentials() . |
|
Return location for error or NULL . |
Returns : |
TRUE if the call succeded, FALSE if error is set. [skip]
|
gboolean goa_account_call_ensure_credentials_sync (GoaAccount *proxy
,gint *out_expires_in
,GCancellable *cancellable
,GError **error
);
Synchronously invokes the EnsureCredentials()
D-Bus method on proxy
. The calling thread is blocked until a reply is received.
See goa_account_call_ensure_credentials()
for the asynchronous version of this method.
|
A GoaAccountProxy. |
|
Return location for return parameter or NULL to ignore. [out]
|
|
A GCancellable or NULL . [allow-none]
|
|
Return location for error or NULL . |
Returns : |
TRUE if the call succeded, FALSE if error is set. [skip]
|
void goa_account_complete_ensure_credentials (GoaAccount *object
,GDBusMethodInvocation *invocation
,gint expires_in
);
Helper function used in service implementations to finish handling invocations of the EnsureCredentials()
D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error()
or similar.
This method will free invocation
, you cannot use it afterwards.
|
A GoaAccount. |
|
A GDBusMethodInvocation. [transfer full] |
|
Parameter to return. |
void goa_account_call_remove (GoaAccount *proxy
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Asynchronously invokes the Remove()
D-Bus method on proxy
.
When the operation is finished, callback
will be invoked in the thread-default main loop of the thread you are calling this method from.
You can then call goa_account_call_remove_finish()
to get the result of the operation.
See goa_account_call_remove_sync()
for the synchronous, blocking version of this method.
|
A GoaAccountProxy. |
|
A GCancellable or NULL . [allow-none]
|
|
A GAsyncReadyCallback to call when the request is satisfied or NULL . |
|
User data to pass to callback . |
gboolean goa_account_call_remove_finish (GoaAccount *proxy
,GAsyncResult *res
,GError **error
);
Finishes an operation started with goa_account_call_remove()
.
|
A GoaAccountProxy. |
|
The GAsyncResult obtained from the GAsyncReadyCallback passed to goa_account_call_remove() . |
|
Return location for error or NULL . |
Returns : |
TRUE if the call succeded, FALSE if error is set. [skip]
|
gboolean goa_account_call_remove_sync (GoaAccount *proxy
,GCancellable *cancellable
,GError **error
);
Synchronously invokes the Remove()
D-Bus method on proxy
. The calling thread is blocked until a reply is received.
See goa_account_call_remove()
for the asynchronous version of this method.
|
A GoaAccountProxy. |
|
A GCancellable or NULL . [allow-none]
|
|
Return location for error or NULL . |
Returns : |
TRUE if the call succeded, FALSE if error is set. [skip]
|
void goa_account_complete_remove (GoaAccount *object
,GDBusMethodInvocation *invocation
);
Helper function used in service implementations to finish handling invocations of the Remove()
D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error()
or similar.
This method will free invocation
, you cannot use it afterwards.
|
A GoaAccount. |
|
A GDBusMethodInvocation. [transfer full] |
struct GoaAccountProxy;
The GoaAccountProxy structure contains only private data and should only be accessed using the provided API.
struct GoaAccountProxyClass { GDBusProxyClass parent_class; };
Class structure for GoaAccountProxy.
GDBusProxyClass |
The parent class. |
void goa_account_proxy_new (GDBusConnection *connection
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Asynchronously creates a proxy for the D-Bus interface org.gnome.OnlineAccounts.Account. See g_dbus_proxy_new()
for more details.
When the operation is finished, callback
will be invoked in the thread-default main loop of the thread you are calling this method from.
You can then call goa_account_proxy_new_finish()
to get the result of the operation.
See goa_account_proxy_new_sync()
for the synchronous, blocking version of this constructor.
|
A GDBusConnection. |
|
Flags from the GDBusProxyFlags enumeration. |
|
A bus name (well-known or unique) or NULL if connection is not a message bus connection. [allow-none]
|
|
An object path. |
|
A GCancellable or NULL . [allow-none]
|
|
A GAsyncReadyCallback to call when the request is satisfied. |
|
User data to pass to callback . |
GoaAccount * goa_account_proxy_new_finish (GAsyncResult *res
,GError **error
);
Finishes an operation started with goa_account_proxy_new()
.
|
The GAsyncResult obtained from the GAsyncReadyCallback passed to goa_account_proxy_new() . |
|
Return location for error or NULL
|
Returns : |
The constructed proxy object or NULL if error is set. [transfer full][type GoaAccountProxy]
|
GoaAccount * goa_account_proxy_new_sync (GDBusConnection *connection
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GError **error
);
Synchronously creates a proxy for the D-Bus interface org.gnome.OnlineAccounts.Account. See g_dbus_proxy_new_sync()
for more details.
The calling thread is blocked until a reply is received.
See goa_account_proxy_new()
for the asynchronous version of this constructor.
|
A GDBusConnection. |
|
Flags from the GDBusProxyFlags enumeration. |
|
A bus name (well-known or unique) or NULL if connection is not a message bus connection. [allow-none]
|
|
An object path. |
|
A GCancellable or NULL . [allow-none]
|
|
Return location for error or NULL
|
Returns : |
The constructed proxy object or NULL if error is set. [transfer full][type GoaAccountProxy]
|
void goa_account_proxy_new_for_bus (GBusType bus_type
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GAsyncReadyCallback callback
,gpointer user_data
);
Like goa_account_proxy_new()
but takes a GBusType instead of a GDBusConnection.
When the operation is finished, callback
will be invoked in the thread-default main loop of the thread you are calling this method from.
You can then call goa_account_proxy_new_for_bus_finish()
to get the result of the operation.
See goa_account_proxy_new_for_bus_sync()
for the synchronous, blocking version of this constructor.
|
A GBusType. |
|
Flags from the GDBusProxyFlags enumeration. |
|
A bus name (well-known or unique). |
|
An object path. |
|
A GCancellable or NULL . [allow-none]
|
|
A GAsyncReadyCallback to call when the request is satisfied. |
|
User data to pass to callback . |
GoaAccount * goa_account_proxy_new_for_bus_finish (GAsyncResult *res
,GError **error
);
Finishes an operation started with goa_account_proxy_new_for_bus()
.
|
The GAsyncResult obtained from the GAsyncReadyCallback passed to goa_account_proxy_new_for_bus() . |
|
Return location for error or NULL
|
Returns : |
The constructed proxy object or NULL if error is set. [transfer full][type GoaAccountProxy]
|
GoaAccount * goa_account_proxy_new_for_bus_sync (GBusType bus_type
,GDBusProxyFlags flags
,const gchar *name
,const gchar *object_path
,GCancellable *cancellable
,GError **error
);
Like goa_account_proxy_new_sync()
but takes a GBusType instead of a GDBusConnection.
The calling thread is blocked until a reply is received.
See goa_account_proxy_new_for_bus()
for the asynchronous version of this constructor.
|
A GBusType. |
|
Flags from the GDBusProxyFlags enumeration. |
|
A bus name (well-known or unique). |
|
An object path. |
|
A GCancellable or NULL . [allow-none]
|
|
Return location for error or NULL
|
Returns : |
The constructed proxy object or NULL if error is set. [transfer full][type GoaAccountProxy]
|
struct GoaAccountSkeleton;
The GoaAccountSkeleton structure contains only private data and should only be accessed using the provided API.
struct GoaAccountSkeletonClass { GDBusInterfaceSkeletonClass parent_class; };
Class structure for GoaAccountSkeleton.
GoaAccount * goa_account_skeleton_new (void
);
Creates a skeleton object for the D-Bus interface org.gnome.OnlineAccounts.Account.
Returns : |
The skeleton object. [transfer full][type GoaAccountSkeleton] |
"attention-needed"
property"attention-needed" gboolean : Read / Write
Represents the D-Bus property "AttentionNeeded".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: FALSE
"id"
property"id" gchar* : Read / Write
Represents the D-Bus property "Id".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"identity"
property"identity" gchar* : Read / Write
Represents the D-Bus property "Identity".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"presentation-identity"
property"presentation-identity" gchar* : Read / Write
Represents the D-Bus property "PresentationIdentity".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"provider-icon"
property"provider-icon" gchar* : Read / Write
Represents the D-Bus property "ProviderIcon".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"provider-name"
property"provider-name" gchar* : Read / Write
Represents the D-Bus property "ProviderName".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"provider-type"
property"provider-type" gchar* : Read / Write
Represents the D-Bus property "ProviderType".
Since the D-Bus property for this GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
Default value: NULL
"handle-ensure-credentials"
signalgboolean user_function (GoaAccount *object,
GDBusMethodInvocation *invocation,
gpointer user_data) : Run Last
Signal emitted when a remote caller is invoking the EnsureCredentials()
D-Bus method.
If a signal handler returns TRUE
, it means the signal handler will handle the invocation (e.g. take a reference to invocation
and eventually call goa_account_complete_ensure_credentials()
or e.g. g_dbus_method_invocation_return_error()
on it) and no order signal handlers will run. If no signal handler handles the invocation, the G_DBUS_ERROR_UNKNOWN_METHOD
error is returned.
|
A GoaAccount. |
|
A GDBusMethodInvocation. |
|
user data set when the signal handler was connected. |
Returns : |
TRUE if the invocation was handled, FALSE to let other signal handlers run. |
"handle-remove"
signalgboolean user_function (GoaAccount *object,
GDBusMethodInvocation *invocation,
gpointer user_data) : Run Last
Signal emitted when a remote caller is invoking the Remove()
D-Bus method.
If a signal handler returns TRUE
, it means the signal handler will handle the invocation (e.g. take a reference to invocation
and eventually call goa_account_complete_remove()
or e.g. g_dbus_method_invocation_return_error()
on it) and no order signal handlers will run. If no signal handler handles the invocation, the G_DBUS_ERROR_UNKNOWN_METHOD
error is returned.
|
A GoaAccount. |
|
A GDBusMethodInvocation. |
|
user data set when the signal handler was connected. |
Returns : |
TRUE if the invocation was handled, FALSE to let other signal handlers run. |