I work on some iphone/android apps and the “data stored on a centralized server” pattern seem fairly common.
So far, I have done one app like this, doing everything myself at a low level without using many libraries:
- MySQL database
- PHP/HTML web forms allowing the app manager to enter/update content with some validation
- PHP scripts turning the SQL data into downloadable XML files
- App code (java/objective-c) to download the XML files, parse them and turn them in some proper objects then displayed in the app UI
As you can imagine, that is very tedious and boring and there is lots of duplicated stuff. Also, it was interesting to do it once that way to understand how it works but I’m sure some libraries do it much better that my own php/java/obj-c code.
Now, I will have to work on something similar and I’m looking for some sort of API/service that will do most of this work for me but still allow me to alter/customize what I need to (e.g.: web form validation so that the app manager doesn’t break the integrity of the database, e.g.: plugging with my own classes).
So I’m looking for the best generic solution that cover all the steps above plus the case when the app can insert/update data as well (download and upload). (Note the library shouldn’t have a licence that prevents me from selling the app)
Let’s say I have to build an app about cars, I want to store the car data in an online SQL database with some HTML forms allowing the app manager to add more cars (but only allowing him to enter validated data). I want the app user to be able to download the cars and insert new one in the online SQL database from his phone.
What library/API would you recommend? What service would save me the most time while still allowing flexibility?