github:https://github.com/greenrobot/greenDAO
先在依赖加上
compile ‘org.greenrobot:greendao-generator:3.2.2‘
compile ‘org.greenrobot:greendao:3.2.2‘
再加上插件
classpath ‘org.greenrobot:greendao-gradle-plugin:3.2.1‘
在需要生成相应greendao加上
apply plugin: ‘org.greenrobot.greendao‘