com.fasterxml.jackson.core

## Class TSFBuilder<F extends JsonFactory,B extends TSFBuilder<F,B>>

- java.lang.Object
- - com.fasterxml.jackson.core.TSFBuilder<F,B>

- Direct Known Subclasses:
    JsonFactoryBuilder

      public abstract class TSFBuilder<F extends JsonFactory,B extends TSFBuilder<F,B>>
      extends Object

  Since 2.10, Builder class is offered for creating token stream factories with difference configurations: with 3.x they will be fully immutable.
  Since:
    2.10

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected int` | `_factoryFeatures` Set of `TokenStreamFactory.Feature`s enabled, as bitmask.
    `protected InputDecorator` | `_inputDecorator` Optional helper object that may decorate input sources, to do additional processing on input during parsing.
    `protected OutputDecorator` | `_outputDecorator` Optional helper object that may decorate output object, to do additional processing on output during content generation.
    `protected int` | `_streamReadFeatures` Set of `JsonParser.Feature`s enabled, as bitmask.
    `protected int` | `_streamWriteFeatures` Set of `JsonGenerator.Feature`s enabled, as bitmask.
    `protected static int` | `DEFAULT_FACTORY_FEATURE_FLAGS` Bitfield (set of flags) of all factory features that are enabled by default.
    `protected static int` | `DEFAULT_GENERATOR_FEATURE_FLAGS` Bitfield (set of flags) of all generator features that are enabled by default.
    `protected static int` | `DEFAULT_PARSER_FEATURE_FLAGS` Bitfield (set of flags) of all parser features that are enabled by default.

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `TSFBuilder()`
    `protected` | `TSFBuilder(int factoryFeatures, int parserFeatures, int generatorFeatures)`
    `protected` | `TSFBuilder(JsonFactory base)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `_legacyDisable(JsonGenerator.Feature f)`
    `protected void` | `_legacyDisable(JsonParser.Feature f)`
    `protected void` | `_legacyEnable(JsonGenerator.Feature f)`
    `protected void` | `_legacyEnable(JsonParser.Feature f)`
    `protected B` | `_this()`
    `abstract F` | `build()` Method for constructing actual `TokenStreamFactory` instance, given configuration.
    `B` | `configure(JsonFactory.Feature f, boolean state)`
    `B` | `configure(JsonReadFeature f, boolean state)`
    `B` | `configure(JsonWriteFeature f, boolean state)`
    `B` | `configure(StreamReadFeature f, boolean state)`
    `B` | `configure(StreamWriteFeature f, boolean state)`
    `B` | `disable(JsonFactory.Feature f)`
    `B` | `disable(JsonReadFeature f)`
    `B` | `disable(JsonReadFeature first, JsonReadFeature... other)`
    `B` | `disable(JsonWriteFeature f)`
    `B` | `disable(JsonWriteFeature first, JsonWriteFeature... other)`
    `B` | `disable(StreamReadFeature f)`
    `B` | `disable(StreamReadFeature first, StreamReadFeature... other)`
    `B` | `disable(StreamWriteFeature f)`
    `B` | `disable(StreamWriteFeature first, StreamWriteFeature... other)`
    `B` | `enable(JsonFactory.Feature f)`
    `B` | `enable(JsonReadFeature f)`
    `B` | `enable(JsonReadFeature first, JsonReadFeature... other)`
    `B` | `enable(JsonWriteFeature f)`
    `B` | `enable(JsonWriteFeature first, JsonWriteFeature... other)`
    `B` | `enable(StreamReadFeature f)`
    `B` | `enable(StreamReadFeature first, StreamReadFeature... other)`
    `B` | `enable(StreamWriteFeature f)`
    `B` | `enable(StreamWriteFeature first, StreamWriteFeature... other)`
    `int` | `factoryFeaturesMask()`
    `InputDecorator` | `inputDecorator()`
    `B` | `inputDecorator(InputDecorator dec)`
    `OutputDecorator` | `outputDecorator()`
    `B` | `outputDecorator(OutputDecorator dec)`
    `int` | `streamReadFeatures()`
    `int` | `streamWriteFeatures()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### DEFAULT_FACTORY_FEATURE_FLAGS

          protected static final int DEFAULT_FACTORY_FEATURE_FLAGS

      Bitfield (set of flags) of all factory features that are enabled by default.

    - #### DEFAULT_PARSER_FEATURE_FLAGS

          protected static final int DEFAULT_PARSER_FEATURE_FLAGS

      Bitfield (set of flags) of all parser features that are enabled by default.

    - #### DEFAULT_GENERATOR_FEATURE_FLAGS

          protected static final int DEFAULT_GENERATOR_FEATURE_FLAGS

      Bitfield (set of flags) of all generator features that are enabled by default.

    - #### _factoryFeatures

          protected int _factoryFeatures

      Set of `TokenStreamFactory.Feature`s enabled, as bitmask.

    - #### _streamReadFeatures

          protected int _streamReadFeatures

      Set of `JsonParser.Feature`s enabled, as bitmask.

    - #### _streamWriteFeatures

          protected int _streamWriteFeatures

      Set of `JsonGenerator.Feature`s enabled, as bitmask.

    - #### _inputDecorator

          protected InputDecorator _inputDecorator

      Optional helper object that may decorate input sources, to do additional processing on input during parsing.

    - #### _outputDecorator

          protected OutputDecorator _outputDecorator

      Optional helper object that may decorate output object, to do additional processing on output during content generation.

  - ### Constructor Detail

    - #### TSFBuilder

          protected TSFBuilder()

    - #### TSFBuilder

          protected TSFBuilder(JsonFactory base)

    - #### TSFBuilder

          protected TSFBuilder(int factoryFeatures,
                               int parserFeatures,
                               int generatorFeatures)

  - ### Method Detail

    - #### factoryFeaturesMask

          public int factoryFeaturesMask()

    - #### streamReadFeatures

          public int streamReadFeatures()

    - #### streamWriteFeatures

          public int streamWriteFeatures()

    - #### inputDecorator

          public InputDecorator inputDecorator()

    - #### outputDecorator

          public OutputDecorator outputDecorator()

    - #### enable

          public B enable(JsonFactory.Feature f)

    - #### disable

          public B disable(JsonFactory.Feature f)

    - #### configure

          public B configure(JsonFactory.Feature f,
                             boolean state)

    - #### enable

          public B enable(StreamReadFeature f)

    - #### enable

          public B enable(StreamReadFeature first,
                          StreamReadFeature... other)

    - #### disable

          public B disable(StreamReadFeature f)

    - #### disable

          public B disable(StreamReadFeature first,
                           StreamReadFeature... other)

    - #### configure

          public B configure(StreamReadFeature f,
                             boolean state)

    - #### enable

          public B enable(StreamWriteFeature f)

    - #### enable

          public B enable(StreamWriteFeature first,
                          StreamWriteFeature... other)

    - #### disable

          public B disable(StreamWriteFeature f)

    - #### disable

          public B disable(StreamWriteFeature first,
                           StreamWriteFeature... other)

    - #### configure

          public B configure(StreamWriteFeature f,
                             boolean state)

    - #### enable

          public B enable(JsonReadFeature f)

    - #### enable

          public B enable(JsonReadFeature first,
                          JsonReadFeature... other)

    - #### disable

          public B disable(JsonReadFeature f)

    - #### disable

          public B disable(JsonReadFeature first,
                           JsonReadFeature... other)

    - #### configure

          public B configure(JsonReadFeature f,
                             boolean state)

    - #### enable

          public B enable(JsonWriteFeature f)

    - #### enable

          public B enable(JsonWriteFeature first,
                          JsonWriteFeature... other)

    - #### disable

          public B disable(JsonWriteFeature f)

    - #### disable

          public B disable(JsonWriteFeature first,
                           JsonWriteFeature... other)

    - #### configure

          public B configure(JsonWriteFeature f,
                             boolean state)

    - #### inputDecorator

          public B inputDecorator(InputDecorator dec)

    - #### outputDecorator

          public B outputDecorator(OutputDecorator dec)

    - #### build

          public abstract F build()

      Method for constructing actual `TokenStreamFactory` instance, given configuration.

    - #### _this

          protected final B _this()

    - #### _legacyEnable

          protected void _legacyEnable(JsonParser.Feature f)

    - #### _legacyDisable

          protected void _legacyDisable(JsonParser.Feature f)

    - #### _legacyEnable

          protected void _legacyEnable(JsonGenerator.Feature f)

    - #### _legacyDisable

          protected void _legacyDisable(JsonGenerator.Feature f)

Copyright © 2008–2019 FasterXML. All rights reserved.