[Bug 38142] proxy factories

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Fri Jul 15 18:49:33 CEST 2011


https://bugs.freedesktop.org/show_bug.cgi?id=38142

--- Comment #54 from Will Thompson <will.thompson at collabora.co.uk> 2011-07-15 09:49:32 PDT ---
+++ b/telepathy-glib/automatic-client-factory-internal.h
@@ -0,0 +1,45 @@
+/*
+ * Automatic client factory internal

Gee, what a helpful description of the file. ;)

I rearranged the arguments of these three functions to put the GError ** last,
and put the factory first. They're methods on the factory, no?

+ * SECTION:automatic-client-factory
+ * @title: TpAutomaticClientFactory
+ * @short_description: factory creating higher level objects

That description tells me even less than the class name. “Factory for
specialized TpChannel subclasses” sounds better. I've changed this.

+#define chainup ((TpSimpleClientFactoryClass *) \
+    tp_automatic_client_factory_parent_class)

This is a new one, I like it in theory—but I think I would have used

  static TpSimpleClientFactoryClass *chainup = NULL;

  ... class_init {
    ...
    chainup = (TpSimpleClientFactoryClass *)
tp_automatic_client_factory_parent_class;
  }

Maybe that's just me.

/* FIXME: This is temporary solution to share TpChannel objects until
 * TpSimpleClientFactory can be used for that */
void
_tp_channel_dispatch_operation_ensure_channels (TpChannelDispatchOperation
*self,
    GPtrArray *channels)

Why can't it be used for that now? How temporary is temporary? What would
actually need to be done to fix this FIXME?

TpAutomaticClientFactory doesn't seem to show up in the generated documentation
for me. At least some of these classes should have code samples for how to
actually used them. I'm lost in a sea of very similarly-named classes whose
documentation describes them as “Factory creating higher level objects” or
“Factory creating higher level proxy objects”.

I have pushed
http://cgit.collabora.com/git/user/wjt/telepathy-glib.git/log/?h=factories
which fixes some documentation nits—plus a build failure and g_object_unref
(NULL) which I found within 30 seconds of cloning the branch ;).

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the telepathy-bugs mailing list