public interface Serializer
Serializers
for various pre-configured serializers.Modifier and Type | Method and Description |
---|---|
boolean |
canDeserialize(javax.json.JsonValue value)
Returns whether this serializer can deserialize the given JsonValue.
|
boolean |
canSerialize(java.lang.Class<?> clazz)
Returns whether this serializer can serialize the given specific class.
|
void |
decrementLevel()
Decrements the level.
|
java.lang.Object |
fromJson(javax.json.JsonValue json)
Deserializes the given Json to an object.
|
void |
incrementLevel()
Increments the level, where the level denotes how far into the structure the current serializer is.
|
javax.json.JsonValue |
toJson(java.lang.Object object)
Serializes the given object to Json.
|
boolean canSerialize(java.lang.Class<?> clazz)
clazz
- The class of the object to be serialized.boolean canDeserialize(javax.json.JsonValue value)
value
- The JsonValue to be deserialized.javax.json.JsonValue toJson(java.lang.Object object)
canSerialize(Class)
object
- The object to be serialized.java.lang.Object fromJson(javax.json.JsonValue json)
canDeserialize(JsonValue)
json
- The JsonValue to be deserializedvoid incrementLevel()
decrementLevel()
.void decrementLevel()
incrementLevel()
.