Enum JsonSerialize.Inclusion
java.lang.Object
java.lang.Enum<JsonSerialize.Inclusion>
com.fasterxml.jackson.databind.annotation.JsonSerialize.Inclusion
- All Implemented Interfaces:
Serializable
,Comparable<JsonSerialize.Inclusion>
,java.lang.constant.Constable
- Enclosing class:
JsonSerialize
Deprecated.
Enumeration used with
JsonSerialize.include()
property
to define which properties
of Java Beans are to be included in serialization-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionDeprecated.Value that indicates that properties are to be always included, independent of valueDeprecated.Pseudo-value that is used to indicate "use whatever is default used at higher level".Deprecated.Value that indicates that only properties that have values that differ from default settings (meaning values they have when Bean is constructed with its no-arguments constructor) are to be included.Deprecated.Value that indicates that only properties that have values that values that are null or what is considered empty are not to be included.Deprecated.Value that indicates that only properties with non-null values are to be included. -
Method Summary
Modifier and TypeMethodDescriptionstatic JsonSerialize.Inclusion
Deprecated.Returns the enum constant of this type with the specified name.static JsonSerialize.Inclusion[]
values()
Deprecated.Returns an array containing the constants of this enum type, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
ALWAYS
Deprecated.Value that indicates that properties are to be always included, independent of value -
NON_NULL
Deprecated.Value that indicates that only properties with non-null values are to be included. -
NON_DEFAULT
Deprecated.Value that indicates that only properties that have values that differ from default settings (meaning values they have when Bean is constructed with its no-arguments constructor) are to be included. Value is generally not useful withMap
s, since they have no default values; and if used, works same asALWAYS
. -
NON_EMPTY
Deprecated.Value that indicates that only properties that have values that values that are null or what is considered empty are not to be included. Emptiness is defined for following type:- For
Collection
s andMap
s, methodisEmpty()
is called; - For Java arrays, empty arrays are ones with length of 0
- For Java
String
s,length()
is called, and return value of 0 indicates empty String
- For
-
DEFAULT_INCLUSION
Deprecated.Pseudo-value that is used to indicate "use whatever is default used at higher level".- Since:
- 2.3
-
-
Method Details
-
values
Deprecated.Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Deprecated.Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-