Hello!
I'm trying to work with opimd for storing phone contacts.
Here what I do to add new contact:
obj = dbus.SessionBus().get_object('org.freesmartphone.opimd',
'/org/freesmartphone/PIM/Contacts')
contacts = dbus.Interface(obj, 'org.freesmartphone.PIM.Contacts')
contact = {'name':'test_name' , 'number':'+48888691184', '
email':'prishelec at gmail.com <email%27%3A%27prishelec at gmail.com>')
contacts.Add(contact);
What I do to retrieve contact knowing phone number:
qw = {'number':'+48888691184'}
query_path = contacts.Query( qw )
queries_obj = dbus.SessionBus().get_object('org.freesmartphone.opimd',
query_path)
query_int = dbus.Interface(queries_obj,
'org.freesmartphone.PIM.ContactQuery')
query_int.Skip(query_int.GetResultCount() -1)
print query_int.GetResult()
So now I have some questions:
1. How to use regular expressions in queries?
2. How to edit entries in contact? All I can do is to add new contact and
query some stuff.
3. If I have say names like Leonti, Leontig, Leontd and so on, after
querying for Leontig I get all of them. Is that intended?
4. Is it possible to delete contact? If so how do I do that.
Hope for understanding.
Leonti
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.openmoko.org/pipermail/devel/attachments/20090415/e68d6a9f/attachment.htm