Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm doing a simple todo-list with QML for Ubuntu phone OS. Is there any standard way for accessing Ubuntu One Database to sync data?

share|improve this question
add comment

1 Answer 1

up vote 7 down vote accepted

There will be; we're working on it. I plan to have the QML U1DB declarative API published soon.

In the meantime, until that arrives, you may find this code interesting; it is a simple notes app, but written with QML and using U1DB. This U1DB QML addition follows the declarative QML U1DB API I mentioned above, but it's a Python-based prototype of that API. So, it's very very hacky indeed, and will be replaced with a proper U1DB QML setup as part of the Ubuntu SDK, but you may find it useful to experiment with. In particular, you'll see from this code how to declaratively declare a U1DB database, indexes, documents, and queries, and from this code that a U1DBQuery is a ListModel. That code should give you some idea of how you will be able to use U1DB from QML in Ubuntu Phone, although I must repeat that the implementation of that API from Python is a hacky prototype.

share|improve this answer
1  
Feel like updating this now that the QML plugin actually exists? –  andrewsomething Sep 27 '13 at 16:43
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.