Top Description Fields Constructors Methods
tools.jackson.core

public final Enum StreamWriteCapability

extends Enum<StreamWriteCapability>
implements JacksonFeature
Class Inheritance
All Implemented Interfaces
tools.jackson.core.util.JacksonFeature
Imports
tools.jackson.core.util.JacksonFeature

Set of on/off capabilities that a JsonGenerator for given format (or in case of buffering, original format) has. Used in some cases to adjust aspects of things like content conversions and coercions by format-agnostic functionality. Specific or expected usage documented by individual capability entry Javadocs.
Since
2.12

Field Summary

Modifier and TypeField and Description
private final boolean
_defaultState

Whether feature is enabled or disabled by default.

private final int
public static final StreamWriteCapability
CAN_WRITE_BINARY_NATIVELY

Capability that indicates that the data format is able to express binary data natively, without using textual encoding like Base64.

public static final StreamWriteCapability
CAN_WRITE_FORMATTED_NUMBERS

Capability that indicates that the data format is able to write "formatted numbers": that is, output of numbers is done as Strings and caller is allowed to pass in logical number values as Strings.

Constructor Summary

AccessConstructor and Description
private
StreamWriteCapability(boolean defaultState)

Method Summary

Modifier and TypeMethod and Description
public boolean
enabledByDefault()

Implements tools.jackson.core.util.JacksonFeature.enabledByDefault.

Accessor for checking whether this feature is enabled by default.

public boolean
enabledIn(int flags)

Implements tools.jackson.core.util.JacksonFeature.enabledIn.

Convenience method for checking whether feature is enabled in given bitmask.

public int
getMask()

Implements tools.jackson.core.util.JacksonFeature.getMask.

Returns bit mask for this feature instance; must be a single bit, that is of form 1 << N.

public static StreamWriteCapability
public static StreamWriteCapability[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

_defaultStateback to summary
private final boolean _defaultState

Whether feature is enabled or disabled by default.

_maskback to summary
private final int _mask
CAN_WRITE_BINARY_NATIVELYback to summary
public static final StreamWriteCapability CAN_WRITE_BINARY_NATIVELY

Capability that indicates that the data format is able to express binary data natively, without using textual encoding like Base64.

Capability is currently enabled for all binary formats and none of textual formats.

CAN_WRITE_FORMATTED_NUMBERSback to summary
public static final StreamWriteCapability CAN_WRITE_FORMATTED_NUMBERS

Capability that indicates that the data format is able to write "formatted numbers": that is, output of numbers is done as Strings and caller is allowed to pass in logical number values as Strings.

Capability is currently enabled for most textual formats and none of binary formats.

Constructor Detail

StreamWriteCapabilityback to summary
private StreamWriteCapability(boolean defaultState)

Method Detail

enabledByDefaultback to summary
public boolean enabledByDefault()

Implements tools.jackson.core.util.JacksonFeature.enabledByDefault.

Doc from tools.jackson.core.util.JacksonFeature.enabledByDefault.

Accessor for checking whether this feature is enabled by default.

Annotations
@Override
enabledInback to summary
public boolean enabledIn(int flags)

Implements tools.jackson.core.util.JacksonFeature.enabledIn.

Doc from tools.jackson.core.util.JacksonFeature.enabledIn.

Convenience method for checking whether feature is enabled in given bitmask.

Annotations
@Override
getMaskback to summary
public int getMask()

Implements tools.jackson.core.util.JacksonFeature.getMask.

Doc from tools.jackson.core.util.JacksonFeature.getMask.

Returns bit mask for this feature instance; must be a single bit, that is of form 1 << N.

Annotations
@Override
valueOfback to summary
public static StreamWriteCapability valueOf(String name)
valuesback to summary
public static StreamWriteCapability[] values()