缺少运行时依赖与所有者,摇篮为Android [英] Missing runtime dependencies with owner, gradle for android
问题描述
我在Android Studio中多模块的设置,它由用于与一个API来通信的一个纯Java模块和一个Android项目,使得使用该API模块组成。要配置API变量,如用户名和密码,我用所有者( http://owner.aeonbits.org/ ) 。整个事情建立没有任何问题。
I have a multi-module setup in Android Studio that consists of one pure java module that is used to communicate with an API, and one Android project that makes use of that API-module. To configure API variables such as usernames and password I use Owner (http://owner.aeonbits.org/). The whole thing builds without problems.
我用一个主功能的API模块中的测试工作的事情很好,这是他们做的。那里。我的问题是,当我尝试运行与API模块它与folling消息崩溃的编译依赖的Android项目:
I use a Main-function in the API module to test that things work well, which they do. There. My problem is that when I try to run the Android project with the compile dependency on the APi-module it crashes with the folling message:
java.lang.NoClassDefFoundError: java.beans.PropertyEditorManager
at org.aeonbits.owner.Converters$4.tryConvert(Converters.java:147)
at org.aeonbits.owner.Converters.doConvert(Converters.java:227)
at org.aeonbits.owner.Converters.convert(Converters.java:222)
at org.aeonbits.owner.PropertiesInvocationHandler.resolveProperty(PropertiesInvocationHandler.java:83)
at org.aeonbits.owner.PropertiesInvocationHandler.invoke(PropertiesInvocationHandler.java:54)
at $Proxy2.local_server_url(Native Method)
at se.springworks.api.client.M2HClient.<init>(M2HClient.java:40)
at se.springworks.apiexample.androidexampleapp.ExampleActivity.onCreate(ExampleActivity.java:18)
at android.app.Activity.performCreate(Activity.java:5426)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2269)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2363)
at android.app.ActivityThread.access$900(ActivityThread.java:161)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1265)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:157)
at android.app.ActivityThread.main(ActivityThread.java:5356)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1265)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1081)
at dalvik.system.NativeStart.main(Native Method)
我不知道这是为什么不工作,但野生刺的是,不是所有的业主从依赖获取包含在出于某种原因,Android项目。
I have no idea why this isn't working but a wild stab is that not all of the dependencies from Owner get included in the Android project for some reason.
编辑:由于在运行期间出现故障,我想知道如果我必须做任何额外的东西来添加为运行时依赖藏汉
Since this fails during runtime, I'm wondering if I have to do anything extra to add this as a runtime dependency aswell.
推荐答案
有没有 java.beans.PropertyEditorManager中
在Android上。你可以看到什么是从包支持在这里的Android API的Javadoc:
There's no java.beans.PropertyEditorManager
on Android. You can see what's supported from that package in the Android API Javadocs here:
http://developer.android.com/reference/java/豆/包summary.html
这篇关于缺少运行时依赖与所有者,摇篮为Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!