本文介绍了用Jack编译器编译Realm项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在Java 1.8中使用realm.io?

How can I use realm.io with Java 1.8?

对于具有Java 1.8的Android,您需要使用jack. Android领域gradle插件和jack的组合似乎不起作用.因为在我添加

For Android with Java 1.8 you need to use jack. The combination of the Android realm gradle plugin and jack seems not to work. Because after I added

apply plugin: 'realm-android'

到我的 app.gradle 文件,我得到

* What went wrong:
A problem occurred configuring project ':app'.
> Could not find property 'options' on task ':app:compileProdDebugJavaWithJack'.

有人知道如何一起工作吗?为什么没有 normal 依赖项?

Does someone know how to get work it together? Why isn't there a normal dependency?

推荐答案

目前不可能.Jack不会产生Realm处理代理类所需的.class文件.

At the moment that's not possible.Jack doesn't produce .class files which are required for Realm to deal with proxy classes.

但是人们对此进行了努力,以便将来有可能 .跟踪这些问题以获取详细信息:

But people work on this so in future that might be possible.Track these issues for details:

  • Realm issue on Github.
  • Jack issue on b.google.com.

这篇关于用Jack编译器编译Realm项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-16 05:21