Skip to content
This repository was archived by the owner on Feb 15, 2024. It is now read-only.
This repository was archived by the owner on Feb 15, 2024. It is now read-only.

Use custom XMLInputFactory and XMLOutputFactory for XML and AASX #59

@kenwenzel

Description

@kenwenzel

Currently the XmlSerializer and XmlDeserializer rely on the standard behavior of Jackson and in the end of the JRE to create instances for XMLInputFactory and XMLOutputFactory.

In some environments - for example within an OSGi container - it may be necessary to provide custom instances for XMLInputFactory and XMLOutputFactory because the JRE is not able to load them from an OSGi bundle.

To use custom instances it is currently required to create subclasses and overwrite the buildMapper methods and replicate the contained code.
I would suggest to extend the constructors for passing an instance of com.fasterxml.jackson.dataformat.xml.XmlFactory.

Also AASXSerializer and AASXDeserializer allow to pass custom instances of the XML (de)serializers but additionaly create a default instance as can be seen here:

private XmlDeserializer deserializer = new XmlDeserializer();

I'll prepare a PR for this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions