我试图从 Eclipse 启动我的 android 应用程序,但是每当我启动应用程序时,它就会卡住,并且我在 LogCat 中收到以下错误
12-15 22:04:03.179: E/AndroidRuntime(1731): java.lang.RuntimeException: Unable to instantiate application com.iiitd.muc.mobishare.c: java.lang.ClassNotFoundException: com.iiitd.muc.mobishare.c in loader dalvik.system.PathClassLoader[/data/app/com.iiitd.muc.mobishare-2.apk]
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.LoadedApk.makeApplication(LoadedApk.java:466)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:3264)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.ActivityThread.access$2200(ActivityThread.java:117)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:973)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.os.Handler.dispatchMessage(Handler.java:99)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.os.Looper.loop(Looper.java:130)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.ActivityThread.main(ActivityThread.java:3687)
12-15 22:04:03.179: E/AndroidRuntime(1731): at java.lang.reflect.Method.invokeNative(Native Method)
12-15 22:04:03.179: E/AndroidRuntime(1731): at java.lang.reflect.Method.invoke(Method.java:507)
12-15 22:04:03.179: E/AndroidRuntime(1731): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)
12-15 22:04:03.179: E/AndroidRuntime(1731): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
12-15 22:04:03.179: E/AndroidRuntime(1731): at dalvik.system.NativeStart.main(Native Method)
12-15 22:04:03.179: E/AndroidRuntime(1731): Caused by: java.lang.ClassNotFoundException: com.iiitd.muc.mobishare.c in loader dalvik.system.PathClassLoader[/data/app/com.iiitd.muc.mobishare-2.apk]
12-15 22:04:03.179: E/AndroidRuntime(1731): at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:240)
12-15 22:04:03.179: E/AndroidRuntime(1731): at java.lang.ClassLoader.loadClass(ClassLoader.java:551)
12-15 22:04:03.179: E/AndroidRuntime(1731): at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.Instrumentation.newApplication(Instrumentation.java:942)
12-15 22:04:03.179: E/AndroidRuntime(1731): at android.app.LoadedApk.makeApplication(LoadedApk.java:461)
更多背景知识:我基本上是想在我的应用程序中添加这个库。http://code.google.com/p/little-fluffy-location-library/
如说明中所述,我已在我的应用程序的 onCreate 方法中添加了这行代码。
LocationLibrary.initialiseLibrary(getBaseContext(), 60 * 1000, 2 * 60 * 1000, "mobi.littlefluffytoys.littlefluffytestclient");
这导致了错误。如果我删除这行代码,应用程序运行良好。
有人可以帮我解决这个错误吗?提前致谢。