Open vitorpamplona opened 2 years ago
Ok, first of all: thank you for contributing this patch! I can see what it is attempting to do and that makes sense.
Unfortunately I am not sure this can be implemented in robust manner: the main problem being that there is no guarantee that
TokenBuffer
) is used (most commonly when @JsonCreator
annotated constructor used)latter might not be a huge issue as long as namespace resolution context is still available, but former is problematic. I guess one could make code check accessibility and avoid lookup if parser not available. But that would be hugely confusing since it "sometimes works, sometimes not" (with no obvious signs to user).
QName is a special case of an XML Deserializer. This PR parses the contents of the QName and assigns the correct namespace from the XML stack. This mimics the behavior of JAXB parsers.
An XML like this:
Should automatically generate a
parent.level1.name
asQName("urn:example:types:r1", "DateTime", "t")