| Access | Constructor and Description |
|---|---|
| public | GuavaOptionalDeserializer(JavaType fullType, ValueInstantiator inst, TypeDeserializer typeDeser, ValueDeserializer<?> deser)
|
| Modifier and Type | Method and Description |
|---|---|
| public Object | getEmptyValue(DeserializationContext ctxt)
Overrides tools. Method called to determine value to be used for "empty" values (most commonly when deserializing from empty JSON Strings). |
| public Optional | getNullValue(DeserializationContext ctxt)
Implements abstract tools. Implements tools. Method that can be called to determine value to be used for
representing null values (values deserialized when JSON token
is |
| public Object | getReferenced(Optional<?> reference)
Implements abstract tools. Method that may be called to find contents of specified reference, if any; or `null` if none. |
| public Optional | referenceValue(Object contents)
Implements abstract tools.
|
| public Optional | updateReference(Optional<?> reference, Object contents)
Implements abstract tools. Method called in case of "merging update", in which we should try update reference instead of creating a new one. |
| public GuavaOptionalDeserializer | withResolved(TypeDeserializer typeDeser, ValueDeserializer<?> valueDeser)
Implements abstract tools. Mutant factory method called when changes are needed; should construct newly configured instance with new values as indicated. |
| GuavaOptionalDeserializer | back to summary |
|---|---|
| public GuavaOptionalDeserializer(JavaType fullType, ValueInstantiator inst, TypeDeserializer typeDeser, ValueDeserializer<?> deser) | |
| getEmptyValue | back to summary |
|---|---|
| public Object getEmptyValue(DeserializationContext ctxt) Overrides tools. Doc from tools. Method called to determine value to be used for "empty" values
(most commonly when deserializing from empty JSON Strings).
Usually this is same as
This method may be called once, or multiple times, depending on what
Default implementation simply calls
| |
| getNullValue | back to summary |
|---|---|
| public Optional Implements abstract tools. Implements tools. Doc from tools. Method that can be called to determine value to be used for
representing null values (values deserialized when JSON token
is
This method may be called once, or multiple times, depending on what
Default implementation simply returns null.
| |
| getReferenced | back to summary |
|---|---|
| public Object getReferenced(Optional<?> reference) Implements abstract tools. Doc from tools. Method that may be called to find contents of specified reference, if any; or `null` if none. Note that method should never fail, so for types that use concept of "absence" vs "presence", `null` is to be returned for both "absent" and "reference to `null`" cases.
| |
| referenceValue | back to summary |
|---|---|
| public Optional Implements abstract tools.
| |
| updateReference | back to summary |
|---|---|
| public Optional Implements abstract tools. Doc from tools. Method called in case of "merging update", in which we should try update reference instead of creating a new one. If this does not succeed, should just create a new instance.
| |
| withResolved | back to summary |
|---|---|
| public GuavaOptionalDeserializer withResolved(TypeDeserializer typeDeser, ValueDeserializer<?> valueDeser) Implements abstract tools. Doc from tools. Mutant factory method called when changes are needed; should construct newly configured instance with new values as indicated. Note caller has verified that there are changes, so implementations need NOT check if a new instance is needed.
| |