[tpm] DBus woes
linux at alteeve.com
Thu Jan 27 17:29:23 PST 2011
On 01/27/2011 03:19 PM, Scott Elcomb wrote:
> Hi all,
> I'd like to start working with Desktop Couch, the DBus + CouchDB
> service behind Ubuntu One.
> As I haven't really worked with DBus before I'm a bit stuck; before I
> go off to bug the desktopcouch list I'd like to make sure I understand
> the Perl side of the issue.
> Here's a really simple little script that is supposed to retrieve the
> port # on which the current user's desktopcouch instance is listening.
> [-- sample starts --]
> #!/usr/bin/env perl
> use strict;
> use warnings;
> use Net::DBus;
> # shell example:
> # dbus-send --session \
> # --dest=org.desktopcouch.CouchDB \
> # --print-reply \
> # --type=method_call / org.desktopcouch.CouchDB.getPort
> my $port_number = -1;
> my $svc_object = Net::DBus->session
> # Doesn't work because $svc_object has no interface
> # $port_number = $svc_object->getPort();
> print "Desktop CouchDB is running on port: $port_number\n";
> [-- sample ends --]
> The desktopcouch specs page refers developers to couchdb-glib
> and (for Perl devs) to Glib::Object::Introspection. On the surface
> it looks to me like  should fix the missing interface issue but I'm
> unsure on how to proceed... I much prefer working with pure perl
> modules and have never needed to wrap a C library before.
> Any help or pointers would be most appreciated.
> - Scott.
>  <http://freedesktop.org/wiki/Specifications/desktopcouch>
>  <https://one.ubuntu.com/>
>  <https://launchpad.net/couchdb-glib>
>  <http://live.gnome.org/GTK2-Perl/Introspection>
E-Mail: digimer at alteeve.com
Node Assassin: http://nodeassassin.org
More information about the toronto-pm