ORM在Android的SQLite和数据库方案

ORM在Android的SQLite和数据库方案

本文介绍了ORM在Android的SQLite和数据库方案的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在寻找一个非常简单的ORM框架工作在Android上的SQLite的。我一直在测试 ActiveAndroid 但没有一个例子所能建立在Eclipse上的。照片顺便说一句,怎么办家伙实施多对多的SQLite,让Android的关系?你如何反映有关删除行的级联,保证数据库的完整性?

I'm looking for a very simple ORM framework working on Android for SQLite. I've been testing ActiveAndroid but none of the example could ever build on Eclipse.
By the way, how do guys implement a "many to many" relationship in SQLite for Android? How do you reflect the cascade regarding deletion of rows and guarantee the database integrity?

推荐答案

我的主要作者 ORMLite 其中有一个Android的后台,这使得调用原生的Andr​​oid OS数据库的API,以支持其ORM功能。我们拥有大量的成功使用框架Android开发者。在这里看到更多的信息:

I am the main author of ORMLite which has a Android backend which makes calls to the native Android OS database APIs to support its ORM functionality. We have a large number of Android developers that are using the framework successfully. See here for more information:

http://ormlite.com/sqlite_java_android_orm.shtml

在多到多的​​关系方面,ORMLite不支持级联或任何更高级的ORM功能,但也有容易多对许多实施例:

In terms of many-to-many relationships, ORMLite does not support cascading or any of the more advanced ORM features but there are examples of easy many-to-many implementations:

http://ormlite.com/docs/examples

这篇关于ORM在Android的SQLite和数据库方案的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-23 09:26