Skip to content

Commit

Permalink
Merge branch '2.19'
Browse files Browse the repository at this point in the history
  • Loading branch information
cowtowncoder committed Oct 30, 2024
2 parents 2cca86f + daf664b commit 37e6a49
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,14 @@
*<p>
* Default value of {@link Mode#DEFAULT} means that caller is to use standard
* heuristics for choosing mode to use.
*
* @return Mode to use.
*/
public Mode mode() default Mode.DEFAULT;

/**
* Enumeration of possible {@link #mode} values available.
*/
public enum Mode {
/**
* Pseudo-mode that indicates that caller is to use default heuristics for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
{
/**
* Id of filter to use; if empty String (""), no filter is to be used.
*
* @return Id of filter to use.
*/
public String value();
}
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@
/**
* Inclusion rule to use for instances (values) of types (Classes) or
* properties annotated; defaults to {@link Include#ALWAYS}.
*
* @return Inclusion rule for value itself
*/
public Include value() default Include.USE_DEFAULTS;

Expand All @@ -60,6 +62,8 @@
* {@link java.util.Map}s and referential types (like
* {@link java.util.concurrent.atomic.AtomicReference});
* defaults to {@link Include#ALWAYS}.
*
* @return Inclusion rule for content (elements, values of structured types)
*/
public Include content() default Include.USE_DEFAULTS;

Expand Down
13 changes: 9 additions & 4 deletions src/main/java/com/fasterxml/jackson/annotation/JsonTypeInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,18 @@ public enum Id {

/**
* Means that no serialized typing-property is used. Types are <i>deduced</i> based
* on the fields available. Deduction is limited to the <i>names</i> of fields
* (not their values or, consequently, any nested descendants). Exceptions will be
* thrown if not enough unique information is present to select a single subtype.
* on the Object properties available in the input.
* Deduction is limited to the <i>names</i> of properties
* (not their values or, consequently, any nested values). Exceptions will be
* thrown if not enough unique information is present to select a single sub-type.
* <br>If deduction is being used annotation properties {@code visible},
* {@code property} and {@code include} are ignored.
* <p>
* On serialization, no type ID is written, and only regular properties are included.
* NOTE: being Property-based, will essentially only work for POJOs and not for
* other kinds of types (like arrays, {@link java.util.Collection}s, {@link java.util.Map}s,
* scalars, etc); similarly, serialized form must be (JSON) Object.
* <p>
* On serialization, no type Id is written, and only regular properties are included.
*
* @since 2.12
*/
Expand Down

0 comments on commit 37e6a49

Please sign in to comment.