greenrobot /greenDAO
greenDAO is a light & fast ORM solution for Android that maps objects to SQLite databases.
★ 12,584⑂ 2,848👁 514⑃ 128● 993▤ 8
12,584
stars
+0+1+-1
2,848
forks
514
watchers
128
prs
993
issues
8
releases
–
discussions
README
⚠️ This project is not longer actively maintained. If you are looking for an easy to use and efficient database solution,
please:
Check out ObjectBox
===================
Check out our new mobile database ObjectBox (GitHub repo).
ObjectBox is a superfast object-oriented database with strong relation support. ObjectBox is embedded into your Android, Linux, macOS, or Windows app.
greenDAO
========
greenDAO is a light & fast ORM for Android that maps objects to SQLite databases. Being highly optimized for Android, greenDAO offers great performance and consumes minimal memory.
Home page, documentation, and support links: https://greenrobot.org/greendao/
Features
--------
greenDAO's unique set of features:
Rock solid: greenDAO has been around since 2011 and is used by countless famous apps
Super simple: concise and straight-forward API, in V3 with annotations
Small: The library is '
classpath 'org.greenrobot:greendao-gradle-plugin:3.3.1' // add plugin
}
}
In your app modules app/build.gradle file:
groovy
apply plugin: 'com.android.application'
apply plugin: 'org.greenrobot.greendao' // apply plugin
dependencies {
implementation 'org.greenrobot:greendao:3.3.0' // add library
}
Note that this hooks up the greenDAO Gradle plugin to your build process. When you build your project, it generates classes like DaoMaster, DaoSession and DAOs.
Continue at the Getting Started page.
R8, ProGuard
------------
If your project uses R8 or ProGuard add the following rules:
bash
-keepclassmembers class extends org.greenrobot.greendao.AbstractDao {
public static java.lang.String TABLENAME;
}
-keep class $Properties { ; }
If you DO use SQLCipher:
-keep class org.greenrobot.greendao.database.SqlCipherEncryptedHelper { ; }
If you do NOT use SQLCipher:
-dontwarn net.sqlcipher.database.
If you do NOT use RxJava:
-dontwarn rx.
Homepage, Documentation, Links
------------------------------
For more details on greenDAO please check greenDAO's website. Here are some direct links you may find useful:
Features
Getting Started
Documentation
Changelog
Technical FAQ
Non-Technical FAQ
Migrating to greenDAO 3
More Open Source by greenrobot
==============================
__ObjectBox__ is a new superfast object-oriented database for mobile.
__EventBus__ is a central publish/subscribe bus for Android with optional delivery threads, priorities, and sticky events. A great tool to decouple components (e.g. Activities, Fragments, logic components) from each other.
__Essentials__ is a set of utility classes and hash functions for Android & Java projects.