What is the minimum version of Java/JDK required to use GSON API? And for gson-2.2.1.jar ?
Gson uses JDK 1.5 features heavily; that's the minimum version for Gson, specifically annotations and generics.
Check out this piece of GSON source code, where annotations are used
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.FIELD)
public @interface SerializedName {
String value();
}
I was facing some issues related with this, the latest version of GSon at the time is 2.8.5 this doesn't work with java 1.5(Minimun 1.6).
The last version of GSon compatible with Java 1.5 is GSon 2.4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With