且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

同步SQLite数据库到App Engine数据存储?

更新时间:2023-02-24 08:40:04

我只写我的数据作为一个String(使用我可以重建我的数据格式),它传递给AE,解析和存储/显示它

I just write out my data as a String (using a format I can reconstruct my data with), pass that to AE, parse it and store/display it.

您可以使用JSON了。

You could use json too.

或尝试的http://mylifewithandroid.blogspot.jp/2010/10/client-server-communication-with-json.html

有关同步部分我使用时间戳。如果时间戳的结果不记录在服务器上,我记录下来。我送录制的邮票到客户端,从商店中删除。当然,服务器也可以发回新的结果,如果用户的记录是从一个不同的客户端更新。

for the sync part I use a timestamp. If the timestamped result isn't recorded on the server, I record it. I send back the recorded stamps to the client and delete them from the store. Of course the server can also send back new results if a user's records were updated from a different client.