Android aws SDK:AndroidRuntime(587):java.lang.NoClassDefFoundError

时间:2012-08-16 12:23:12

标签: android amazon-web-services amazon-simpledb

我正在尝试将AWS Simple DB与androidSdk 1.3.3一起使用,这是我的连接代码

AWSCredentials credits = new BasicAWSCredentials("apkey","secretkey");
AmazonSimpleDBClient client = new AmazonSimpleDBClient(credits);

我添加了必要的Jar,但是我得到一个异常指向AwsCredentials并且我的logcat说

E/AndroidRuntime(587): java.lang.NoClassDefFoundError: com.amazonaws.auth.BasicAWSCredentials 

我可以知道我哪里错了吗?

LogCat报告:

08-16 17:33:04.484: E/AndroidRuntime(587): FATAL EXCEPTION: main
08-16 17:33:04.484: E/AndroidRuntime(587): java.lang.NoClassDefFoundError: com.amazonaws.auth.BasicAWSCredentials
08-16 17:33:04.484: E/AndroidRuntime(587):  at com.Ews.EwsActivity.<init>(EwsActivity.java:24)
08-16 17:33:04.484: E/AndroidRuntime(587):  at java.lang.Class.newInstanceImpl(Native Method)
08-16 17:33:04.484: E/AndroidRuntime(587):  at java.lang.Class.newInstance(Class.java:1319)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.Instrumentation.newActivity(Instrumentation.java:1023)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1871)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1981)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.ActivityThread.access$600(ActivityThread.java:123)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1147)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.os.Handler.dispatchMessage(Handler.java:99)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.os.Looper.loop(Looper.java:137)
08-16 17:33:04.484: E/AndroidRuntime(587):  at android.app.ActivityThread.main(ActivityThread.java:4424)
08-16 17:33:04.484: E/AndroidRuntime(587):  at java.lang.reflect.Method.invokeNative(Native Method)
08-16 17:33:04.484: E/AndroidRuntime(587):  at java.lang.reflect.Method.invoke(Method.java:511)
08-16 17:33:04.484: E/AndroidRuntime(587):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
08-16 17:33:04.484: E/AndroidRuntime(587):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
08-16 17:33:04.484: E/AndroidRuntime(587):  at dalvik.system.NativeStart.main(Native Method)

0 个答案:

没有答案