Package com.fasterxml.jackson.dataformat.xml

## Class XmlFactoryBuilder

- java.lang.Object
- - com.fasterxml.jackson.core.TSFBuilder<XmlFactory,​XmlFactoryBuilder>
  - - com.fasterxml.jackson.dataformat.xml.XmlFactoryBuilder

    public class XmlFactoryBuilder
    extends com.fasterxml.jackson.core.TSFBuilder<XmlFactory,​XmlFactoryBuilder>

`TSFBuilder` implementation for constructing `XmlFactory` instances.

Since:
  3.0

### Field Summary

Fields
`protected int` `_formatGeneratorFeatures` Set of `ToXmlGenerator.Feature`s enabled, as bitmask.
`protected int` `_formatParserFeatures` Set of `FromXmlParser.Feature`s enabled, as bitmask.
`protected java.lang.String` `_nameForTextElement` In cases where a start element has both attributes and non-empty textual value, we have to create a bogus property; we will use this as the property name.
`protected javax.xml.stream.XMLInputFactory` `_xmlInputFactory` Stax factory for creating underlying input stream readers; `null` for "use default instance with default settings"
`protected javax.xml.stream.XMLOutputFactory` `_xmlOutputFactory` Stax factory for creating underlying output stream writers; `null` for "use default instance with default settings"

### Fields inherited from class com.fasterxml.jackson.core.TSFBuilder

`_factoryFeatures, _inputDecorator, _outputDecorator, _streamReadFeatures, _streamWriteFeatures, DEFAULT_FACTORY_FEATURE_FLAGS, DEFAULT_GENERATOR_FEATURE_FLAGS, DEFAULT_PARSER_FEATURE_FLAGS`

### Constructor Summary

Constructors
`protected` `XmlFactoryBuilder()`
`` `XmlFactoryBuilder​(XmlFactory base)`

### Method Summary

All Methods Static Methods Instance Methods Concrete Methods
`XmlFactory` `build()`
`XmlFactoryBuilder` `configure​(FromXmlParser.Feature f, boolean state)`
`XmlFactoryBuilder` `configure​(ToXmlGenerator.Feature f, boolean state)`
`protected static javax.xml.stream.XMLInputFactory` `defaultInputFactory()`
`protected static javax.xml.stream.XMLOutputFactory` `defaultOutputFactory()`
`XmlFactoryBuilder` `disable​(FromXmlParser.Feature f)`
`XmlFactoryBuilder` `disable​(FromXmlParser.Feature first, FromXmlParser.Feature... other)`
`XmlFactoryBuilder` `disable​(ToXmlGenerator.Feature f)`
`XmlFactoryBuilder` `disable​(ToXmlGenerator.Feature first, ToXmlGenerator.Feature... other)`
`XmlFactoryBuilder` `enable​(FromXmlParser.Feature f)`
`XmlFactoryBuilder` `enable​(FromXmlParser.Feature first, FromXmlParser.Feature... other)`
`XmlFactoryBuilder` `enable​(ToXmlGenerator.Feature f)`
`XmlFactoryBuilder` `enable​(ToXmlGenerator.Feature first, ToXmlGenerator.Feature... other)`
`int` `formatGeneratorFeaturesMask()`
`int` `formatParserFeaturesMask()`
`XmlFactoryBuilder` `inputFactory​(javax.xml.stream.XMLInputFactory xmlIn)`
`java.lang.String` `nameForTextElement()`
`XmlFactoryBuilder` `nameForTextElement​(java.lang.String name)`
`XmlFactoryBuilder` `outputFactory​(javax.xml.stream.XMLOutputFactory xmlOut)`
`javax.xml.stream.XMLInputFactory` `xmlInputFactory()`
`javax.xml.stream.XMLOutputFactory` `xmlOutputFactory()`

### Methods inherited from class com.fasterxml.jackson.core.TSFBuilder

`_legacyDisable, _legacyDisable, _legacyEnable, _legacyEnable, _this, configure, configure, configure, configure, configure, disable, disable, disable, disable, disable, disable, disable, disable, disable, enable, enable, enable, enable, enable, enable, enable, enable, enable, factoryFeaturesMask, inputDecorator, inputDecorator, outputDecorator, outputDecorator, streamReadFeatures, streamWriteFeatures`

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

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

### Field Detail

#### _formatParserFeatures

    protected int _formatParserFeatures

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

#### _formatGeneratorFeatures

    protected int _formatGeneratorFeatures

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

#### _xmlInputFactory

    protected javax.xml.stream.XMLInputFactory _xmlInputFactory

Stax factory for creating underlying input stream readers; `null` for "use default instance with default settings"

#### _xmlOutputFactory

    protected javax.xml.stream.XMLOutputFactory _xmlOutputFactory

Stax factory for creating underlying output stream writers; `null` for "use default instance with default settings"

#### _nameForTextElement

    protected java.lang.String _nameForTextElement

In cases where a start element has both attributes and non-empty textual value, we have to create a bogus property; we will use this as the property name.

Name used for pseudo-property used for returning XML Text value (which does not have actual element name to use). Defaults to empty String, but may be changed for inter-operability reasons: JAXB, for example, uses "value" as name.

### Constructor Detail

#### XmlFactoryBuilder

    protected XmlFactoryBuilder()

#### XmlFactoryBuilder

    public XmlFactoryBuilder​(XmlFactory base)

### Method Detail

#### formatParserFeaturesMask

    public int formatParserFeaturesMask()

#### formatGeneratorFeaturesMask

    public int formatGeneratorFeaturesMask()

#### nameForTextElement

    public java.lang.String nameForTextElement()

#### xmlInputFactory

    public javax.xml.stream.XMLInputFactory xmlInputFactory()

#### defaultInputFactory

    protected static javax.xml.stream.XMLInputFactory defaultInputFactory()

#### xmlOutputFactory

    public javax.xml.stream.XMLOutputFactory xmlOutputFactory()

#### defaultOutputFactory

    protected static javax.xml.stream.XMLOutputFactory defaultOutputFactory()

#### enable

    public XmlFactoryBuilder enable​(FromXmlParser.Feature f)

#### enable

    public XmlFactoryBuilder enable​(FromXmlParser.Feature first,
                                    FromXmlParser.Feature... other)

#### disable

    public XmlFactoryBuilder disable​(FromXmlParser.Feature f)

#### disable

    public XmlFactoryBuilder disable​(FromXmlParser.Feature first,
                                     FromXmlParser.Feature... other)

#### configure

    public XmlFactoryBuilder configure​(FromXmlParser.Feature f,
                                       boolean state)

#### enable

    public XmlFactoryBuilder enable​(ToXmlGenerator.Feature f)

#### enable

    public XmlFactoryBuilder enable​(ToXmlGenerator.Feature first,
                                    ToXmlGenerator.Feature... other)

#### disable

    public XmlFactoryBuilder disable​(ToXmlGenerator.Feature f)

#### disable

    public XmlFactoryBuilder disable​(ToXmlGenerator.Feature first,
                                     ToXmlGenerator.Feature... other)

#### configure

    public XmlFactoryBuilder configure​(ToXmlGenerator.Feature f,
                                       boolean state)

#### nameForTextElement

    public XmlFactoryBuilder nameForTextElement​(java.lang.String name)

#### inputFactory

    public XmlFactoryBuilder inputFactory​(javax.xml.stream.XMLInputFactory xmlIn)

#### outputFactory

    public XmlFactoryBuilder outputFactory​(javax.xml.stream.XMLOutputFactory xmlOut)

#### build

    public XmlFactory build()

Specified by:
  `build` in class `com.fasterxml.jackson.core.TSFBuilder<XmlFactory,​XmlFactoryBuilder>`