mirror of
https://github.com/jwtk/jjwt.git
synced 2025-03-09 06:46:50 +00:00
Updated RuntimeClasspath Serializer/Deserializer
This commit is contained in:
parent
747238a479
commit
9bf487f0b7
@ -34,6 +34,8 @@ public class RuntimeClasspathDeserializerLocator<T> implements InstanceLocator<D
|
||||
return Classes.newInstance("io.jsonwebtoken.io.JacksonDeserializer");
|
||||
} else if (isAvailable("org.json.JSONObject")) {
|
||||
return Classes.newInstance("io.jsonwebtoken.io.OrgJsonDeserializer");
|
||||
} else if (isAvailable("com.google.gson.GsonBuilder")) {
|
||||
return Classes.newInstance("io.jsonwebtoken.io.GsonDeSerializer");
|
||||
} else {
|
||||
throw new IllegalStateException("Unable to discover any JSON Deserializer implementations on the classpath.");
|
||||
}
|
||||
|
@ -34,6 +34,8 @@ public class RuntimeClasspathSerializerLocator implements InstanceLocator<Serial
|
||||
return Classes.newInstance("io.jsonwebtoken.io.JacksonSerializer");
|
||||
} else if (isAvailable("org.json.JSONObject")) {
|
||||
return Classes.newInstance("io.jsonwebtoken.io.OrgJsonSerializer");
|
||||
} else if (isAvailable("com.google.gson.GsonBuilder")) {
|
||||
return Classes.newInstance("io.jsonwebtoken.io.GsonSerializer");
|
||||
} else {
|
||||
throw new IllegalStateException("Unable to discover any JSON Serializer implementations on the classpath.");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user