summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWill Thompson <will.thompson@collabora.co.uk>2011-08-30 15:46:57 +0100
committerWill Thompson <will.thompson@collabora.co.uk>2011-10-10 18:08:57 +0100
commitc176abf6162264ced42c630491f48ca8f4a337f4 (patch)
tree0a9522fe26c5ae914faa1dd555e3cc7794f93649
parent4f70e8891881d1ee8c612df34a73bd34829d725d (diff)
Expose tp_svc_interface_get_dbus_properties_info
I find myself wanting this while writing RoomConfig support. Admittedly once that code is in tp-glib it won't strictly need to be exported, but I think it's harmless enough.
-rw-r--r--docs/reference/telepathy-glib-sections.txt1
-rw-r--r--telepathy-glib/dbus-properties-mixin.c16
-rw-r--r--telepathy-glib/dbus-properties-mixin.h2
3 files changed, 17 insertions, 2 deletions
diff --git a/docs/reference/telepathy-glib-sections.txt b/docs/reference/telepathy-glib-sections.txt
index 01e12f7b..7ff0e399 100644
--- a/docs/reference/telepathy-glib-sections.txt
+++ b/docs/reference/telepathy-glib-sections.txt
@@ -2189,6 +2189,7 @@ TP_TYPE_DBUS_PROPERTIES_MIXIN_FLAGS
TpDBusPropertiesMixinIfaceInfo
TpDBusPropertiesMixinPropInfo
tp_svc_interface_set_dbus_properties_info
+tp_svc_interface_get_dbus_properties_info
<SUBSECTION>
TpDBusPropertiesMixinClass
TpDBusPropertiesMixinIfaceImpl
diff --git a/telepathy-glib/dbus-properties-mixin.c b/telepathy-glib/dbus-properties-mixin.c
index 2331f338..290ad506 100644
--- a/telepathy-glib/dbus-properties-mixin.c
+++ b/telepathy-glib/dbus-properties-mixin.c
@@ -193,8 +193,20 @@ tp_svc_interface_set_dbus_properties_info (GType g_interface,
g_type_set_qdata (g_interface, q, info);
}
-/* could make this public, but it doesn't seem necessary yet */
-static TpDBusPropertiesMixinIfaceInfo *
+/**
+ * tp_svc_interface_get_dbus_properties_info:
+ * @g_interface: The #GType of a service interface
+ *
+ * Retrieves the D-Bus property metadata for the given interface, if any.
+ * This function is typically not useful outside telepathy-glib itself, but may
+ * be useful for domain-specific variations on the theme of SetProperty. If in
+ * doubt, you probably don't need this function.
+ *
+ * Returns: D-Bus property metadata for @g_interface, or %NULL if it has
+ * none.
+ * Since: UNRELEASED
+ */
+TpDBusPropertiesMixinIfaceInfo *
tp_svc_interface_get_dbus_properties_info (GType g_interface)
{
return g_type_get_qdata (g_interface, _iface_prop_info_quark ());
diff --git a/telepathy-glib/dbus-properties-mixin.h b/telepathy-glib/dbus-properties-mixin.h
index 54f33515..262b9f01 100644
--- a/telepathy-glib/dbus-properties-mixin.h
+++ b/telepathy-glib/dbus-properties-mixin.h
@@ -56,6 +56,8 @@ typedef struct {
void tp_svc_interface_set_dbus_properties_info (GType g_interface,
TpDBusPropertiesMixinIfaceInfo *info);
+TpDBusPropertiesMixinIfaceInfo *tp_svc_interface_get_dbus_properties_info (
+ GType g_interface);
/* ---- Concrete implementation (in GObject subclasses) ------------- */