Package com.fasterxml.jackson.annotation
Annotation Type JsonApplyView
-
@Target({ANNOTATION_TYPE,CONSTRUCTOR,FIELD,METHOD}) @Retention(RUNTIME) public @interface JsonApplyViewAnnotation used for specifying view that should be used to process the property that is defined by method or field annotated.An example annotation would be:
@JsonApplyView(BasicView.class) public MyValue value;
which specifies that the property annotated (and nested values reach through it) would be processed using View identified byBasicView.class.It is also possible to disable View processing for given property by:
@JsonApplyView(JsonApplyView.NONE.class) public MyValue fullValue;
which similarly applies to properties reachable viafullValue.Note: initially processing only covers serialization.
- Since:
- 2.22
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.Class<?>valueView that should be used to process annotated property, if any; special valueJsonApplyView.NONEindicates that no View should used.
-
-
-
Element Detail
-
value
java.lang.Class<?> value
View that should be used to process annotated property, if any; special valueJsonApplyView.NONEindicates that no View should used.
-
-