Class StdKeySerializers
- java.lang.Object
-
- com.fasterxml.jackson.databind.ser.std.StdKeySerializers
-
public abstract class StdKeySerializers extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
StdKeySerializers.Default
This is a "chameleon" style multi-type key serializer for simple standard JDK types.static class
StdKeySerializers.Dynamic
Key serializer used when key type is not known statically, and actual key serializer needs to be dynamically located.static class
StdKeySerializers.EnumKeySerializer
Specialized instance to use for Enum keys, as per [databind#1322]static class
StdKeySerializers.StringKeySerializer
Simple and fast key serializer when keys are Strings.
-
Constructor Summary
Constructors Constructor Description StdKeySerializers()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static JsonSerializer<java.lang.Object>
getDefault()
Deprecated.since 2.7static JsonSerializer<java.lang.Object>
getFallbackKeySerializer(SerializationConfig config, java.lang.Class<?> rawKeyType)
Method called if no specified key serializer was located; will return a "default" key serializer.static JsonSerializer<java.lang.Object>
getStdKeySerializer(SerializationConfig config, java.lang.Class<?> rawKeyType, boolean useDefault)
-
-
-
Method Detail
-
getStdKeySerializer
public static JsonSerializer<java.lang.Object> getStdKeySerializer(SerializationConfig config, java.lang.Class<?> rawKeyType, boolean useDefault)
- Parameters:
config
- Serialization configuration in use, may be needed in choosing serializer to userawKeyType
- Type of key values to serializeuseDefault
- If no match is found, should we return fallback deserializer (true), or null (false)?
-
getFallbackKeySerializer
public static JsonSerializer<java.lang.Object> getFallbackKeySerializer(SerializationConfig config, java.lang.Class<?> rawKeyType)
Method called if no specified key serializer was located; will return a "default" key serializer.- Since:
- 2.7
-
getDefault
@Deprecated public static JsonSerializer<java.lang.Object> getDefault()
Deprecated.since 2.7
-
-