Class AbstractCustomJacksonSerializer<T>
java.lang.Object
com.fasterxml.jackson.databind.JsonSerializer<T>
com.fasterxml.jackson.databind.ser.std.StdSerializer<T>
com.graphql_java_generator.client.request.AbstractCustomJacksonSerializer<T>
- All Implemented Interfaces:
com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitable
,com.fasterxml.jackson.databind.jsonschema.SchemaAware
,Serializable
public abstract class AbstractCustomJacksonSerializer<T>
extends com.fasterxml.jackson.databind.ser.std.StdSerializer<T>
Jackson Deserializer for lists and Custom Scalars.
- Author:
- etienne-sf
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.fasterxml.jackson.databind.JsonSerializer
com.fasterxml.jackson.databind.JsonSerializer.None
-
Field Summary
Fields inherited from class com.fasterxml.jackson.databind.ser.std.StdSerializer
_handledType
-
Constructor Summary
ConstructorDescriptionAbstractCustomJacksonSerializer
(Class<?> clazz, int listLevel, graphql.schema.GraphQLScalarType graphQLScalarType) -
Method Summary
Methods inherited from class com.fasterxml.jackson.databind.ser.std.StdSerializer
_neitherNull, _nonEmpty, acceptJsonFormatVisitor, createSchemaNode, createSchemaNode, findAnnotatedContentSerializer, findContextualConvertingSerializer, findConvertingContentSerializer, findFormatFeature, findFormatOverrides, findIncludeOverrides, findPropertyFilter, getSchema, getSchema, handledType, isDefaultSerializer, visitArrayFormat, visitArrayFormat, visitFloatFormat, visitIntFormat, visitIntFormat, visitStringFormat, visitStringFormat, wrapAndThrow, wrapAndThrow
Methods inherited from class com.fasterxml.jackson.databind.JsonSerializer
getDelegatee, isEmpty, isEmpty, isUnwrappingSerializer, properties, replaceDelegatee, serializeWithType, unwrappingSerializer, usesObjectId, withFilterId
-
Constructor Details
-
AbstractCustomJacksonSerializer
public AbstractCustomJacksonSerializer(Class<?> clazz, int listLevel, graphql.schema.GraphQLScalarType graphQLScalarType) - Parameters:
graphQLScalarType
- TheGraphQLScalarType
instance that manages this Custom Scalar. It's used to deserialize the value read on the Jackson response from the server It is mandatory for custom scalars, and must null for other data types.clazz
- Theclass. It's a Class<?>
because of issues with generics.listLevel
- The depth of the GraphQL list. 0 means it's not a list. 1 is a standard list. 2 is a list of list...
-
-
Method Details
-
serialize
public void serialize(T value, com.fasterxml.jackson.core.JsonGenerator gen, com.fasterxml.jackson.databind.SerializerProvider provider) throws IOException - Specified by:
serialize
in classcom.fasterxml.jackson.databind.ser.std.StdSerializer<T>
- Throws:
IOException
-