![]() |
![]() |
![]() |
telepathy-glib API Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
Connection Contacts interfaceConnection Contacts interface — client-side wrappers for the Contacts interface |
#include <telepathy-glib/telepathy-glib-dbus.h> TpProxyPendingCall * tp_cli_connection_interface_contacts_call_get_contact_attributes (TpConnection *proxy
,gint timeout_ms
,const GArray *in_Handles
,const gchar **in_Interfaces
,tp_cli_connection_interface_contacts_callback_for_get_contact_attributes callback
,gpointer user_data
,GDestroyNotify destroy
,GObject *weak_object
); void (*tp_cli_connection_interface_contacts_callback_for_get_contact_attributes) (TpConnection *proxy
,GHashTable *out_Attributes
,const GError *error
,gpointer user_data
,GObject *weak_object
); TpProxyPendingCall * tp_cli_connection_interface_contacts_call_get_contact_by_id (TpConnection *proxy
,gint timeout_ms
,const gchar *in_Identifier
,const gchar **in_Interfaces
,tp_cli_connection_interface_contacts_callback_for_get_contact_by_id callback
,gpointer user_data
,GDestroyNotify destroy
,GObject *weak_object
); void (*tp_cli_connection_interface_contacts_callback_for_get_contact_by_id) (TpConnection *proxy
,guint out_Handle
,GHashTable *out_Attributes
,const GError *error
,gpointer user_data
,GObject *weak_object
);
This interface allows a client to get information from various connection interfaces in one dbus call.
This section documents the auto-generated C wrappers for the Contacts interface, used with TpConnection objects.
TpProxyPendingCall * tp_cli_connection_interface_contacts_call_get_contact_attributes (TpConnection *proxy
,gint timeout_ms
,const GArray *in_Handles
,const gchar **in_Interfaces
,tp_cli_connection_interface_contacts_callback_for_get_contact_attributes callback
,gpointer user_data
,GDestroyNotify destroy
,GObject *weak_object
);
Start a GetContactAttributes method call.
Return any number of contact attributes for the given handles.
|
the TpProxy |
|
the timeout in milliseconds, or -1 to use the default |
|
Used to pass an 'in' argument: An array of handles representing contacts. |
|
Used to pass an 'in' argument: <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>A list of strings indicating which D-Bus interfaces the calling process is interested in. All supported attributes from these interfaces, whose values can be obtained without additional network activity, will be in the reply.</p> <p>Attributes from the interface <tp:dbus-ref>im.telepathy1.Connection</tp:dbus-ref> are always returned, and need not be requested explicitly.</p> <p>As well as returning cached information immediately, the connection MAY start asynchronous requests to obtain better values for the contact attributes. If better values are later obtained by this process, they will be indicated with the usual signals (such as <tp:dbus-ref namespace="im.telepathy1.Connection.Interface.Aliasing1">AliasesChanged</tp:dbus-ref>).</p> <tp:rationale> For instance, an XMPP connection manager could download vCards in response to a request for <tp:dbus-ref namespace="im.telepathy1.Connection.Interface">Aliasing1</tp:dbus-ref> attributes. </tp:rationale> |
|
called when the method call succeeds or fails;
may be NULL to make a "fire and forget" call with no
reply tracking |
|
user-supplied data passed to the callback;
must be NULL if callback is NULL
|
|
called with the user_data as argument, after the
call has succeeded, failed or been cancelled;
must be NULL if callback is NULL
|
|
If not NULL , a GObject which will be
weakly referenced; if it is destroyed, this call
will automatically be cancelled. Must be NULL if
callback is NULL
|
Returns : |
a TpProxyPendingCall representing the call in progress. It is borrowed from the object, and will become invalid when the callback is called, the call is cancelled or the TpProxy becomes invalid. |
void (*tp_cli_connection_interface_contacts_callback_for_get_contact_attributes) (TpConnection *proxy
,GHashTable *out_Attributes
,const GError *error
,gpointer user_data
,GObject *weak_object
);
Signature of the callback called when a GetContactAttributes method call succeeds or fails.
|
the proxy on which the call was made |
|
Used to return an 'out' argument if error is NULL : <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>A dictionary mapping the contact handles to contact attributes. If any of the requested handles are in fact invalid, they are simply omitted from this mapping. If contact attributes are not immediately known, the behaviour is defined by the interface; the attribute should either be omitted from the result or replaced with a default value.</p> <p>Each contact's attributes will always include at least the identifier that would be obtained by inspecting the handle (<code>im.telepathy1.Connection/contact-id</code>).</p> |
|
NULL on success, or an error on failure |
|
user-supplied data |
|
user-supplied object |
TpProxyPendingCall * tp_cli_connection_interface_contacts_call_get_contact_by_id (TpConnection *proxy
,gint timeout_ms
,const gchar *in_Identifier
,const gchar **in_Interfaces
,tp_cli_connection_interface_contacts_callback_for_get_contact_by_id callback
,gpointer user_data
,GDestroyNotify destroy
,GObject *weak_object
);
Start a GetContactByID method call.
Return any number of contact attributes for the given identifier. <tp:rationale> This is for a single identifier to make it simpler to use for the most common use case. For multiple contacts case, <tp:member-ref>GetContactAttributes</tp:member-ref> should be used. </tp:rationale>
|
the TpProxy |
|
the timeout in milliseconds, or -1 to use the default |
|
Used to pass an 'in' argument: An identifier representing a contact. |
|
Used to pass an 'in' argument: <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>A list of strings indicating which D-Bus interfaces the calling process is interested in. All supported attributes from these interfaces, whose values can be obtained without additional network activity, will be in the reply.</p> <p>See <tp:member-ref>GetContactAttributes</tp:member-ref> for details.</p> |
|
called when the method call succeeds or fails;
may be NULL to make a "fire and forget" call with no
reply tracking |
|
user-supplied data passed to the callback;
must be NULL if callback is NULL
|
|
called with the user_data as argument, after the
call has succeeded, failed or been cancelled;
must be NULL if callback is NULL
|
|
If not NULL , a GObject which will be
weakly referenced; if it is destroyed, this call
will automatically be cancelled. Must be NULL if
callback is NULL
|
Returns : |
a TpProxyPendingCall representing the call in progress. It is borrowed from the object, and will become invalid when the callback is called, the call is cancelled or the TpProxy becomes invalid. |
void (*tp_cli_connection_interface_contacts_callback_for_get_contact_by_id) (TpConnection *proxy
,guint out_Handle
,GHashTable *out_Attributes
,const GError *error
,gpointer user_data
,GObject *weak_object
);
Signature of the callback called when a GetContactByID method call succeeds or fails.
|
the proxy on which the call was made |
|
Used to return an 'out' argument if error is NULL : <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>The contact's handle</p> (TpContactHandle) |
|
Used to return an 'out' argument if error is NULL : <tp:docstring xmlns="http://www.w3.org/1999/xhtml"> <p>All supported attributes of the contact on the given interfaces that can be returned without network round-trips. If contact attributes are not immediately known, the behaviour is defined by the interface; the attribute should either be omitted from the result or replaced with a default value.</p> <p>The contact's attributes will always include at least the identifier that would be obtained by inspecting the handle (<code>org.freedesktop.Telepathy.Connection/contact-id</code>).</p> |
|
NULL on success, or an error on failure |
|
user-supplied data |
|
user-supplied object |