public interface VisibilityChecker<T extends VisibilityChecker<T>>
Note on type declaration: funky recursive type is necessary to support builder/fluent pattern.
Modifier and Type | Interface and Description |
---|---|
static class |
VisibilityChecker.Std
Default standard implementation is purely based on visibility
modifier of given class members, and its configured minimum
levels.
|
Modifier and Type | Method and Description |
---|---|
boolean |
isCreatorVisible(AnnotatedMember m) |
boolean |
isCreatorVisible(Member m)
Method for checking whether given method is auto-detectable
as Creator, with respect to its visibility (not considering
method signature or name, just visibility)
|
boolean |
isFieldVisible(AnnotatedField f) |
boolean |
isFieldVisible(Field f)
Method for checking whether given field is auto-detectable
as property, with respect to its visibility (not considering
method signature or name, just visibility)
|
boolean |
isGetterVisible(AnnotatedMethod m) |
boolean |
isGetterVisible(Method m)
Method for checking whether given method is auto-detectable
as regular getter, with respect to its visibility (not considering
method signature or name, just visibility)
|
boolean |
isIsGetterVisible(AnnotatedMethod m) |
boolean |
isIsGetterVisible(Method m)
Method for checking whether given method is auto-detectable
as is-getter, with respect to its visibility (not considering
method signature or name, just visibility)
|
boolean |
isSetterVisible(AnnotatedMethod m) |
boolean |
isSetterVisible(Method m)
Method for checking whether given method is auto-detectable
as setter, with respect to its visibility (not considering
method signature or name, just visibility)
|
T |
with(JsonAutoDetect.Visibility v)
Builder method that will create and return an instance that has specified
JsonAutoDetect.Visibility value to use for all property elements. |
T |
with(JsonAutoDetect ann)
Builder method that will return an instance that has same
settings as this instance has, except for values that
given annotation overrides.
|
T |
withCreatorVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for creator methods
(constructors, factory methods)
|
T |
withFieldVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for fields.
|
T |
withGetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for regular ("getXxx") getters.
|
T |
withIsGetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for "is-getters" ("isXxx").
|
T |
withOverrides(JsonAutoDetect.Value vis)
Method that can be used for merging default values from `this`
instance with specified overrides; and either return `this`
if overrides had no effect (that is, result would be equal),
or a new instance with merged visibility settings.
|
T |
withSetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for setters.
|
T |
withVisibility(PropertyAccessor method,
JsonAutoDetect.Visibility v)
Builder method that will create and return an instance that has specified
JsonAutoDetect.Visibility value to use for specified property. |
T with(JsonAutoDetect ann)
T withOverrides(JsonAutoDetect.Value vis)
T with(JsonAutoDetect.Visibility v)
JsonAutoDetect.Visibility
value to use for all property elements.
Typical usage would be something like:
mapper.setVisibilityChecker( mapper.getVisibilityChecker().with(Visibility.NONE));(which would basically disable all auto-detection)
T withVisibility(PropertyAccessor method, JsonAutoDetect.Visibility v)
JsonAutoDetect.Visibility
value to use for specified property.
Typical usage would be:
mapper.setVisibilityChecker( mapper.getVisibilityChecker().withVisibility(JsonMethod.FIELD, Visibility.ANY));(which would basically enable auto-detection for all member fields)
T withGetterVisibility(JsonAutoDetect.Visibility v)
T withIsGetterVisibility(JsonAutoDetect.Visibility v)
T withSetterVisibility(JsonAutoDetect.Visibility v)
T withCreatorVisibility(JsonAutoDetect.Visibility v)
T withFieldVisibility(JsonAutoDetect.Visibility v)
boolean isGetterVisible(Method m)
boolean isGetterVisible(AnnotatedMethod m)
boolean isIsGetterVisible(Method m)
boolean isIsGetterVisible(AnnotatedMethod m)
boolean isSetterVisible(Method m)
boolean isSetterVisible(AnnotatedMethod m)
boolean isCreatorVisible(Member m)
boolean isCreatorVisible(AnnotatedMember m)
boolean isFieldVisible(Field f)
boolean isFieldVisible(AnnotatedField f)
Copyright © 2008–2019 FasterXML. All rights reserved.