public static class VisibilityChecker.Std extends java.lang.Object implements VisibilityChecker<VisibilityChecker.Std>, java.io.Serializable
VisibilityChecker.Std
Constructor and Description |
---|
Std(JsonAutoDetect.Visibility v)
Constructor that will assign given visibility value for all
properties.
|
Std(JsonAutoDetect.Visibility getter,
JsonAutoDetect.Visibility isGetter,
JsonAutoDetect.Visibility setter,
JsonAutoDetect.Visibility creator,
JsonAutoDetect.Visibility field)
Constructor that allows directly specifying minimum visibility levels to use
|
Std(JsonAutoDetect ann)
Constructor used for building instance that has minumum visibility
levels as indicated by given annotation instance
|
Modifier and Type | Method and Description |
---|---|
static VisibilityChecker.Std |
construct(JsonAutoDetect.Value vis) |
static VisibilityChecker.Std |
defaultInstance() |
boolean |
isCreatorVisible(AnnotatedMember m) |
boolean |
isCreatorVisible(java.lang.reflect.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(java.lang.reflect.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(java.lang.reflect.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(java.lang.reflect.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(java.lang.reflect.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)
|
java.lang.String |
toString() |
VisibilityChecker.Std |
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. |
VisibilityChecker.Std |
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.
|
VisibilityChecker.Std |
withCreatorVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for creator methods
(constructors, factory methods)
|
VisibilityChecker.Std |
withFieldVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for fields.
|
VisibilityChecker.Std |
withGetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for regular ("getXxx") getters.
|
VisibilityChecker.Std |
withIsGetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for "is-getters" ("isXxx").
|
VisibilityChecker.Std |
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.
|
VisibilityChecker.Std |
withSetterVisibility(JsonAutoDetect.Visibility v)
Builder method that will return a checker instance that has
specified minimum visibility level for setters.
|
VisibilityChecker.Std |
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. |
public Std(JsonAutoDetect ann)
ann
- Annotations to use for determining minimum visibility levelspublic Std(JsonAutoDetect.Visibility getter, JsonAutoDetect.Visibility isGetter, JsonAutoDetect.Visibility setter, JsonAutoDetect.Visibility creator, JsonAutoDetect.Visibility field)
public Std(JsonAutoDetect.Visibility v)
v
- level to use for all property typespublic static VisibilityChecker.Std defaultInstance()
public static VisibilityChecker.Std construct(JsonAutoDetect.Value vis)
public VisibilityChecker.Std with(JsonAutoDetect ann)
VisibilityChecker
with
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withOverrides(JsonAutoDetect.Value vis)
VisibilityChecker
withOverrides
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std with(JsonAutoDetect.Visibility v)
VisibilityChecker
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)
with
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withVisibility(PropertyAccessor method, JsonAutoDetect.Visibility v)
VisibilityChecker
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)
withVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withGetterVisibility(JsonAutoDetect.Visibility v)
VisibilityChecker
withGetterVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withIsGetterVisibility(JsonAutoDetect.Visibility v)
VisibilityChecker
withIsGetterVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withSetterVisibility(JsonAutoDetect.Visibility v)
VisibilityChecker
withSetterVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withCreatorVisibility(JsonAutoDetect.Visibility v)
VisibilityChecker
withCreatorVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public VisibilityChecker.Std withFieldVisibility(JsonAutoDetect.Visibility v)
VisibilityChecker
withFieldVisibility
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isCreatorVisible(java.lang.reflect.Member m)
VisibilityChecker
isCreatorVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isCreatorVisible(AnnotatedMember m)
isCreatorVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isFieldVisible(java.lang.reflect.Field f)
VisibilityChecker
isFieldVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isFieldVisible(AnnotatedField f)
isFieldVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isGetterVisible(java.lang.reflect.Method m)
VisibilityChecker
isGetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isGetterVisible(AnnotatedMethod m)
isGetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isIsGetterVisible(java.lang.reflect.Method m)
VisibilityChecker
isIsGetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isIsGetterVisible(AnnotatedMethod m)
isIsGetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isSetterVisible(java.lang.reflect.Method m)
VisibilityChecker
isSetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public boolean isSetterVisible(AnnotatedMethod m)
isSetterVisible
in interface VisibilityChecker<VisibilityChecker.Std>
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2010 - 2020 Adobe. All Rights Reserved