参照ライブラリで Gson jar を使用する Android アプリがあります。現在、バージョン 2.2.4 を使用しており、テスト用に 2 台の電話を使用しています。
Samsung Galaxy S Advance 2.3.6 ではすべてが完全に動作しますが、LG Nexus 4 4.2.2 ではエラーが発生しました
The JAR gson-2.4.4 has no source attachment.
およびログファイル
java.Lang.StackoverflowError
もちろん、必要なライブラリを正しくインポートしました。そうしないと、Android 2.3.6 では機能しませんでした。
何か提案はありますか?
ありがとう
これはスタックです:
05-28 14:58:50.540: E/AndroidRuntime(1038): FATAL EXCEPTION: Thread-92
05-28 14:58:50.540: E/AndroidRuntime(1038): java.lang.StackOverflowError
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:380)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:375)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.$Gson$Types.resolve($Gson$Types.java:355)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:117)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.Gson.getAdapter(Gson.java:356)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.Gson.getAdapter(Gson.java:356)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.Gson.getAdapter(Gson.java:356)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.Gson.getAdapter(Gson.java:356)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82)
05-28 14:58:50.540: E/AndroidRuntime(1038): at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81)