Further WIP towards greendao:

- for now, use a custom version of greendao with the fix 39ac07be550c5f5b6fd265c8870f58015c95e908
- use a superclass for activity sample classes that provides value normalization using SampleProvider
This commit is contained in:
cpfeiffer
2016-05-01 23:56:14 +02:00
parent 4744d8b59e
commit 70eaca8883
4 changed files with 20 additions and 18 deletions
+2 -1
View File
@@ -6,7 +6,8 @@ archivesBaseName = 'gadgetbridge-daogenerator'
//version = '0.9.2-SNAPSHOT'
dependencies {
compile 'org.greenrobot:greendao-generator:2.2.0'
// compile 'org.greenrobot:greendao-generator:2.2.0'
compile 'com.github.freeyourgadget:greendao:c3830951e5dd3d1e63d7bac600d5f773b81df363'
}
sourceSets {
@@ -115,6 +115,7 @@ public class GBDaoGenerator {
}
private static void addCommonAcivitySampleProperties(Schema schema, Entity activitySample, Entity user, Entity device) {
activitySample.setSuperclass("AbstractActivitySample");
activitySample.addImport(MODEL_PACKAGE + ".ActivitySample");
activitySample.addImport(MAIN_PACKAGE + ".devices.SampleProvider");
activitySample.implementsInterface("ActivitySample");