嘿,我正在开发一个 android 应用程序,我遇到了一个问题,我想为我的 android 应用程序开发一个 web http 服务器,通过我的研究,我遇到了这个例子
每当我尝试运行它时,我都会遇到这种我不知道如何解决的错误,有没有人遇到过这个错误或类似的错误?我正在使用 eclipse 并尝试在 android 4.2.2 和 4.1.2 上运行它
05-23 12:53:18.351: D/dalvikvm(626): Not late-enabling CheckJNI (already on)
05-23 12:53:19.112: E/Trace(626): error opening trace file: No such file or directory (2)
05-23 12:53:19.461: W/dalvikvm(626): Unable to resolve superclass of Lcom/example/jettytest/MainActivity$1; (641)
05-23 12:53:19.461: W/dalvikvm(626): Link of class 'Lcom/example/jettytest/MainActivity$1;' failed
05-23 12:53:19.461: E/dalvikvm(626): Could not find class 'com.example.jettytest.MainActivity$1', referenced from method com.example.jettytest.MainActivity.<init>
05-23 12:53:19.461: W/dalvikvm(626): VFY: unable to resolve new-instance 536 (Lcom/example/jettytest/MainActivity$1;) in Lcom/example/jettytest/MainActivity;
05-23 12:53:19.461: D/dalvikvm(626): VFY: replacing opcode 0x22 at 0x0003
05-23 12:53:19.471: E/dalvikvm(626): Could not find class 'org.eclipse.jetty.server.Server', referenced from method com.example.jettytest.MainActivity.onCreate
05-23 12:53:19.471: W/dalvikvm(626): VFY: unable to resolve new-instance 640 (Lorg/eclipse/jetty/server/Server;) in Lcom/example/jettytest/MainActivity;
05-23 12:53:19.471: D/dalvikvm(626): VFY: replacing opcode 0x22 at 0x0008
05-23 12:53:19.471: W/dalvikvm(626): Unable to resolve superclass of Lcom/example/jettytest/MainActivity$1; (641)
05-23 12:53:19.471: W/dalvikvm(626): Link of class 'Lcom/example/jettytest/MainActivity$1;' failed
05-23 12:53:19.471: D/dalvikvm(626): DexOpt: unable to opt direct call 0x0ff3 at 0x05 in Lcom/example/jettytest/MainActivity;.<init>
05-23 12:53:19.471: D/dalvikvm(626): DexOpt: unable to opt direct call 0x10bf at 0x0c in Lcom/example/jettytest/MainActivity;.onCreate
05-23 12:53:19.481: D/AndroidRuntime(626): Shutting down VM
05-23 12:53:19.481: W/dalvikvm(626): threadid=1: thread exiting with uncaught exception (group=0x40a13300)
05-23 12:53:19.491: E/AndroidRuntime(626): FATAL EXCEPTION: main
05-23 12:53:19.491: E/AndroidRuntime(626): java.lang.NoClassDefFoundError: com.example.jettytest.MainActivity$1
05-23 12:53:19.491: E/AndroidRuntime(626): at com.example.jettytest.MainActivity.<init>(MainActivity.java:26)
05-23 12:53:19.491: E/AndroidRuntime(626): at java.lang.Class.newInstanceImpl(Native Method)
05-23 12:53:19.491: E/AndroidRuntime(626): at java.lang.Class.newInstance(Class.java:1319)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.Instrumentation.newActivity(Instrumentation.java:1053)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1974)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2084)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.ActivityThread.access$600(ActivityThread.java:130)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1195)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.os.Handler.dispatchMessage(Handler.java:99)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.os.Looper.loop(Looper.java:137)
05-23 12:53:19.491: E/AndroidRuntime(626): at android.app.ActivityThread.main(ActivityThread.java:4745)
05-23 12:53:19.491: E/AndroidRuntime(626): at java.lang.reflect.Method.invokeNative(Native Method)
05-23 12:53:19.491: E/AndroidRuntime(626): at java.lang.reflect.Method.invoke(Method.java:511)
05-23 12:53:19.491: E/AndroidRuntime(626): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
05-23 12:53:19.491: E/AndroidRuntime(626): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
05-23 12:53:19.491: E/AndroidRuntime(626): at dalvik.system.NativeStart.main(Native Method)
05-23 12:53:21.291: I/Process(626): Sending signal. PID: 626 SIG: 9