FilteringGeneratorDelegate.
| Modifier and Type | Class and Description |
|---|---|
| public static enum | TokenFilter.
Enumeration that controls how TokenFilter return values are interpreted. |
| Modifier and Type | Field and Description |
|---|---|
| public static final TokenFilter | INCLUDE_ALL
Marker value that should be used to indicate inclusion of a structured value (sub-tree representing Object or Array), or value of a named property (regardless of type). |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| protected boolean | Returns: Whether all leaf scalar values should be included (true)
or not (false)Overridable default implementation delegated to all scalar value inclusion check methods. |
| public void | filterFinishArray()
Method called to indicate that output of non-filtered Array (one that may
have been included either completely, or in part) is completed,
in cases where filter other that |
| public void | filterFinishObject()
Method called to indicate that output of non-filtered Object (one that may
have been included either completely, or in part) is completed,
in cases where filter other that |
| public TokenFilter | Returns: TokenFilter to use for further calls within Array, unless return value isnull or INCLUDE_ALL (which have simpler semantics)Method called to check whether Array value at current output location should be included in output. |
| public TokenFilter | Returns: TokenFilter to use for further calls within Array, unless return value isnull or INCLUDE_ALL (which have simpler semantics)Method called to check whether Object value at current output location should be included in output. |
| public boolean | Returns: True if the binary value is to be included; false if notCall made to verify whether leaf-level Binary value should be included in output or not. |
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level boolean value should be included in output or not. |
| public TokenFilter | Returns: TokenFilter to use for further calls within element value, unless return value isnull or INCLUDE_ALL (which have simpler semantics)Array element index (0-based) to check index)Method called to check whether array element with specified index (zero-based), at current output location, should be included in output. |
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level embedded (Opaque) value should be included in output or not. |
| public boolean | Returns: True if value is to be included; false if notTrue if Array had contents but they were
filtered out (NOT included); false if we had actual empty Array. contentsFiltered)Call made to verify whether leaf-level empty Array value should be included in output or not. |
| public boolean | Returns: True if value is to be included; false if notTrue if Object had contents but they were
filtered out (NOT included); false if we had actual empty Object. contentsFiltered)Call made to verify whether leaf-level empty Object value should be included in output or not. |
| public boolean | Returns: True if (null) value is to be included; false if notCall made to verify whether leaf-level null value should be included in output or not. |
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level
|
| public TokenFilter | Returns: TokenFilter to use for further calls within property value, unless return value isnull or INCLUDE_ALL (which have simpler semantics)Name of Object property to check name)Method called to check whether property value with specified name, at current output location, should be included in output. |
| public boolean | Returns: True if the raw value is to be included; false if notCall made to verify whether leaf-level raw (pre-encoded, not quoted by generator) value should be included in output or not. |
| public TokenFilter | Returns: TokenFilter to use for further calls within root value, unless return value isnull or INCLUDE_ALL (which have simpler semantics)Index (0-based) of the root value to check index)Method called to check whether root-level value, at current output location, should be included in output. |
| public boolean | Returns: True if value is to be included; false if notValue to check value)Call made to verify whether leaf-level String value should be included in output or not. |
| public boolean | Returns: True if value is to be included; false if notReader used to pass String value to parser r, int indicated maximum length of String value maxLen)Call made to verify whether leaf-level "streaming" String value should be included in output or not. |
| public boolean | Returns: True if scalar value is to be included; false if notParser that points to the value (typically p)delegate
parser, not filtering parser that wraps it)Call made when verifying whether a scalar value is being read from a parser. |
| public String |
| INCLUDE_ALL | back to summary |
|---|---|
| public static final TokenFilter INCLUDE_ALL Marker value that should be used to indicate inclusion of a structured value (sub-tree representing Object or Array), or value of a named property (regardless of type). Note that if this instance is returned, it will used as a marker, and no actual callbacks need to be made. For this reason, it is more efficient to return this instance if the whole sub-tree is to be included, instead of implementing similar filter functionality explicitly. | |
| TokenFilter | back to summary |
|---|---|
| protected TokenFilter() | |
| _includeScalar | back to summary |
|---|---|
| protected boolean _includeScalar() Overridable default implementation delegated to all scalar value inclusion check methods. The default implementation simply includes all leaf values.
| |
| filterFinishArray | back to summary |
|---|---|
| public void filterFinishArray() Method called to indicate that output of non-filtered Array (one that may
have been included either completely, or in part) is completed,
in cases where filter other that | |
| filterFinishObject | back to summary |
|---|---|
| public void filterFinishObject() Method called to indicate that output of non-filtered Object (one that may
have been included either completely, or in part) is completed,
in cases where filter other that | |
| filterStartArray | back to summary |
|---|---|
| public TokenFilter filterStartArray() Method called to check whether Array value at current output location should be included in output. Three kinds of return values may be used as follows:
Default implementation returns
| |
| filterStartObject | back to summary |
|---|---|
| public TokenFilter filterStartObject() Method called to check whether Object value at current output location should be included in output. Three kinds of return values may be used as follows:
Default implementation returns
| |
| includeBinary | back to summary |
|---|---|
| public boolean includeBinary() Call made to verify whether leaf-level Binary value should be included in output or not. Note no binary payload passed; assumption is this won't be of much use.
| |
| includeBoolean | back to summary |
|---|---|
| public boolean includeBoolean(boolean value) Call made to verify whether leaf-level boolean value should be included in output or not.
| |
| includeElement | back to summary |
|---|---|
| public TokenFilter includeElement(int index) Method called to check whether array element with specified index (zero-based), at current output location, should be included in output. Three kinds of return values may be used as follows:
The default implementation simply returns
| |
| includeEmbeddedValue | back to summary |
|---|---|
| public boolean includeEmbeddedValue(Object value) Call made to verify whether leaf-level embedded (Opaque) value should be included in output or not.
| |
| includeEmptyArray | back to summary |
|---|---|
| public boolean includeEmptyArray(boolean contentsFiltered) Call made to verify whether leaf-level empty Array value should be included in output or not.
| |
| includeEmptyObject | back to summary |
|---|---|
| public boolean includeEmptyObject(boolean contentsFiltered) Call made to verify whether leaf-level empty Object value should be included in output or not.
| |
| includeNull | back to summary |
|---|---|
| public boolean includeNull() Call made to verify whether leaf-level null value should be included in output or not.
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(int value) Call made to verify whether leaf-level
Note also called for `short`, `byte`
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(long value) Call made to verify whether leaf-level
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(float value) Call made to verify whether leaf-level
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(double value) Call made to verify whether leaf-level
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(BigDecimal value) Call made to verify whether leaf-level
| |
| includeNumber | back to summary |
|---|---|
| public boolean includeNumber(BigInteger value) Call made to verify whether leaf-level
| |
| includeProperty | back to summary |
|---|---|
| public TokenFilter includeProperty(String name) Method called to check whether property value with specified name, at current output location, should be included in output. Three kinds of return values may be used as follows:
The default implementation simply returns
| |
| includeRawValue | back to summary |
|---|---|
| public boolean includeRawValue() Call made to verify whether leaf-level raw (pre-encoded, not quoted by generator) value should be included in output or not. Note value itself not passed since it may come on multiple forms and is unlikely to be of much use in determining inclusion criteria.
| |
| includeRootValue | back to summary |
|---|---|
| public TokenFilter includeRootValue(int index) Method called to check whether root-level value, at current output location, should be included in output. Three kinds of return values may be used as follows:
The default implementation simply returns
| |
| includeString | back to summary |
|---|---|
| public boolean includeString(String value) Call made to verify whether leaf-level String value should be included in output or not.
| |
| includeString | back to summary |
|---|---|
| public boolean includeString(Reader r, int maxLen) Call made to verify whether leaf-level "streaming" String value should be included in output or not. Note note that any reads from passed in
| |
| includeValue | back to summary |
|---|---|
| public boolean includeValue(JsonParser p) throws IOException Call made when verifying whether a scalar value is being read from a parser.
Default action is to call
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
| Modifier and Type | Field and Description |
|---|---|
| public static final TokenFilter. | INCLUDE_ALL_AND_PATH
When TokenFilter.INCLUDE_ALL is returned, the corresponding token will be included as well as enclosing tokens up to the root |
| public static final TokenFilter. | INCLUDE_NON_NULL
Tokens will be included if any non-null filter is returned. |
| public static final TokenFilter. | ONLY_INCLUDE_ALL
Tokens will only be included if the filter returns TokenFilter.INCLUDE_ALL |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static TokenFilter. | |
| public static TokenFilter. |
| INCLUDE_ALL_AND_PATH | back to summary |
|---|---|
| public static final TokenFilter. When TokenFilter.INCLUDE_ALL is returned, the corresponding token will be included as well as enclosing tokens up to the root | |
| INCLUDE_NON_NULL | back to summary |
|---|---|
| public static final TokenFilter. Tokens will be included if any non-null filter is returned. The exception is if a field name returns a non-null filter, but the field value returns a null filter. In this case the field name and value will both be omitted. | |
| ONLY_INCLUDE_ALL | back to summary |
|---|---|
| public static final TokenFilter. Tokens will only be included if the filter returns TokenFilter.INCLUDE_ALL | |
| Inclusion | back to summary |
|---|---|
| private Inclusion() | |
| valueOf | back to summary |
|---|---|
| public static TokenFilter. | |
| values | back to summary |
|---|---|
| public static TokenFilter. | |