From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH 3/3] test: Add a test script to get service properties
Date: Thu, 09 Aug 2012 01:44:58 -0500 [thread overview]
Message-ID: <50235C6A.8030308@gmail.com> (raw)
In-Reply-To: <1344527503-9965-4-git-send-email-ronald.tessier@linux.intel.com>
[-- Attachment #1: Type: text/plain, Size: 1215 bytes --]
Hi Ronald,
On 08/09/2012 10:51 AM, Ronald Tessier wrote:
> ---
> test/get-properties | 26 ++++++++++++++++++++++++++
> 1 file changed, 26 insertions(+)
> create mode 100755 test/get-properties
>
> diff --git a/test/get-properties b/test/get-properties
> new file mode 100755
> index 0000000..8887fcb
> --- /dev/null
> +++ b/test/get-properties
> @@ -0,0 +1,26 @@
> +#!/usr/bin/python
> +
> +import sys
> +import dbus
> +
> +bus = dbus.SessionBus()
> +
> +manager = dbus.Interface(bus.get_object('org.ofono.mms', '/org/ofono/mms'),
> + 'org.ofono.mms.Manager')
> +
> +services = manager.GetServices()
> +path = services[0][0]
> +
> +service = dbus.Interface(bus.get_object('org.ofono.mms', path),
> + 'org.ofono.mms.Service')
> +
> +properties = service.GetProperties()
> +
> +for p in properties:
> + if len(properties[p].__str__())> 0:
> + print "%s Service Manager rule is: %s" %\
> + (p, properties[p])
> + print "------------------------------------------" \
> + "-----------------"
> + else:
> + print "%s Service Manager rule disabled" % (p)
Please model this script after list-modems in ofono. Name it list-services.
Regards,
-Denis
prev parent reply other threads:[~2012-08-09 6:44 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-09 15:51 [PATCH 0/3] mmsd: Add GetProperties method Ronald Tessier
2012-08-09 15:51 ` [PATCH 1/3] service: Add DBus method to get service properties Ronald Tessier
2012-08-09 6:43 ` Denis Kenzior
2012-08-09 15:51 ` [PATCH 2/3] doc: Describe GetProperties in service-api Ronald Tessier
2012-08-09 6:43 ` Denis Kenzior
2012-08-09 15:51 ` [PATCH 3/3] test: Add a test script to get service properties Ronald Tessier
2012-08-09 6:44 ` Denis Kenzior [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50235C6A.8030308@gmail.com \
--to=denkenz@gmail.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox