FasterXML / FasterXML/jackson-dataformat-xml

Write namespace declaration on root element only?

Open
#670 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
631
Forks
246
Avg merge
7d 9h
Merged PRs (30d)
13

Description

Hello and thank you for such an awesome project!

I'm using dataformat-xml to create a video manifest (MPEG-DASH mpd), and for aesthetic reasons I'd really like if it could write all namespace declarations on the root element.

The XML I generate currently looks like this:
```xml


https://example.com/license

```

but I want to move the "xmlns:dashif="https://dashif.org/guidelines/clearKey"" to . Like this:

```xml


https://example.com/license

```

Is it possible to configure / override something in XmlMapper or Woodstox to make this work?

Thanks a lot,
Anton

Java 21 with `com.fasterxml.jackson.dataformat:jackson-dataformat-xml:2.17.2`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.