public enum JacksonOption extends Enum<JacksonOption>
JacksonModule's processing.| Enum Constant and Description |
|---|
FLATTENED_ENUMS_FROM_JSONPROPERTY
Use this option to treat enum types with a
JsonProperty annotation on each of its
constants as plain strings in the generated schema. |
FLATTENED_ENUMS_FROM_JSONVALUE
Use this option to treat enum types with a
JsonValue annotation on one of its methods as
plain strings in the generated schema. |
IGNORE_PROPERTY_NAMING_STRATEGY
Use this option to skip property name changes according to
JsonNaming annotations. |
IGNORE_TYPE_INFO_TRANSFORM
Use this option to skip the transformation according to
@JsonTypeInfo annotations (typically used to identify specific subtypes). |
INCLUDE_ONLY_JSONPROPERTY_ANNOTATED_METHODS
Use this option to ignore all methods that don't have a
JsonProperty annotation
themselves or in case of getter methods on their associated field. |
RESPECT_JSONPROPERTY_ORDER
Use this option to sort an object's properties according to associated
JsonPropertyOrder annotations. |
RESPECT_JSONPROPERTY_REQUIRED
Use this option to include fields annotated with
@JsonProperty(required = true) in the containing type's list of "required" properties. |
SKIP_SUBTYPE_LOOKUP
Use this option to skip the automatic look-up of subtypes according to
@JsonSubTypes annotations. |
| Modifier and Type | Method and Description |
|---|---|
static JacksonOption |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static JacksonOption[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final JacksonOption FLATTENED_ENUMS_FROM_JSONVALUE
JsonValue annotation on one of its methods as
plain strings in the generated schema. If no such annotation with value = true is present on exactly one argument-free method, it will
fall-back on following custom definitions (e.g. from one of the standard generator Options).
FLATTENED_ENUMS_FROM_JSONPROPERTY option, with the JsonValue annotation taking
precedence.public static final JacksonOption FLATTENED_ENUMS_FROM_JSONPROPERTY
JsonProperty annotation on each of its
constants as plain strings in the generated schema. If no such annotation is present on each enum constants, it will fall-back on following
custom definitions (e.g. from one of the standard generator Options).
FLATTENED_ENUMS_FROM_JSONVALUE option, with the JsonValue annotation taking
precedence.public static final JacksonOption RESPECT_JSONPROPERTY_ORDER
JsonPropertyOrder annotations. Fields and methods without such an annotation are
listed after annotated properties.public static final JacksonOption INCLUDE_ONLY_JSONPROPERTY_ANNOTATED_METHODS
JsonProperty annotation
themselves or in case of getter methods on their associated field. When including non-getter methods with annotated property names, you'll
probably want to enable the general Option.FIELDS_DERIVED_FROM_ARGUMENTFREE_METHODS as well, in order to avoid parentheses at the end.Option.FIELDS_DERIVED_FROM_ARGUMENTFREE_METHODSpublic static final JacksonOption IGNORE_PROPERTY_NAMING_STRATEGY
JsonNaming annotations.public static final JacksonOption SKIP_SUBTYPE_LOOKUP
@JsonSubTypes annotations.public static final JacksonOption IGNORE_TYPE_INFO_TRANSFORM
@JsonTypeInfo annotations (typically used to identify specific subtypes).public static final JacksonOption RESPECT_JSONPROPERTY_REQUIRED
@JsonProperty(required = true) in the containing type's list of "required" properties.public static JacksonOption[] values()
for (JacksonOption c : JacksonOption.values()) System.out.println(c);
public static JacksonOption valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullCopyright © 2021 VicTools. All rights reserved.