static void aliasing_fill_contact_attributes (GObject *object, const GArray *contacts, GHashTable *attributes) { ExampleContactListConnection *self = EXAMPLE_CONTACT_LIST_CONNECTION (object); guint i; for (i = 0; i < contacts->len; i++) { TpHandle contact = g_array_index (contacts, guint, i); tp_contacts_mixin_set_contact_attribute (attributes, contact, TP_TOKEN_CONNECTION_INTERFACE_ALIASING_ALIAS, tp_g_value_slice_new_string ( example_contact_list_manager_get_alias (self->priv->list_manager, contact))); } }
static void conn_location_fill_contact_attributes (GObject *obj, const GArray *contacts, GHashTable *attributes_hash) { GabbleConnection *self = GABBLE_CONNECTION (obj); guint i; for (i = 0; i < contacts->len; i++) { TpHandle handle = g_array_index (contacts, TpHandle, i); GHashTable *location = get_cached_location (self, handle); if (location != NULL) { GValue *val = tp_g_value_slice_new_take_boxed ( TP_HASH_TYPE_STRING_VARIANT_MAP, location); tp_contacts_mixin_set_contact_attribute (attributes_hash, handle, TP_IFACE_CONNECTION_INTERFACE_LOCATION"/location", val); } } }