Java Code Examples for org.apache.tinkerpop.shaded.jackson.databind.jsontype.TypeSerializer#writeTypeSuffixForObject()
The following examples show how to use
org.apache.tinkerpop.shaded.jackson.databind.jsontype.TypeSerializer#writeTypeSuffixForObject() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: JavaUtilSerializersV3d0.java From tinkerpop with Apache License 2.0 | 5 votes |
@Override public void serializeWithType(final Map map, final JsonGenerator jsonGenerator, final SerializerProvider serializerProvider, final TypeSerializer typeSerializer) throws IOException { typeSerializer.writeTypePrefixForObject(map, jsonGenerator); serialize(map, jsonGenerator, serializerProvider); typeSerializer.writeTypeSuffixForObject(map, jsonGenerator); }
Example 2
Source File: JavaUtilSerializersV2d0.java From tinkerpop with Apache License 2.0 | 5 votes |
@Override public void serializeWithType(final Map.Entry entry, final JsonGenerator jsonGenerator, final SerializerProvider serializerProvider, final TypeSerializer typeSerializer) throws IOException { typeSerializer.writeTypePrefixForObject(entry, jsonGenerator); ser(entry, jsonGenerator, serializerProvider); typeSerializer.writeTypeSuffixForObject(entry, jsonGenerator); }
Example 3
Source File: JavaTimeSerializersV1d0.java From tinkerpop with Apache License 2.0 | 5 votes |
@Override public void serializeWithType(final T value, final JsonGenerator gen, final SerializerProvider serializers, final TypeSerializer typeSer) throws IOException { typeSer.writeTypePrefixForObject(value, gen); gen.writeStringField(GraphSONTokens.VALUE, value.toString()); typeSer.writeTypeSuffixForObject(value, gen); }
Example 4
Source File: GraphSONUtil.java From tinkerpop with Apache License 2.0 | 4 votes |
public static void writeEndObject(final Object o, final JsonGenerator jsonGenerator, final TypeSerializer typeSerializer) throws IOException { if (typeSerializer != null) typeSerializer.writeTypeSuffixForObject(o, jsonGenerator); else jsonGenerator.writeEndObject(); }