Add jackson support
It would be nice have jackson integration like yaml has https://github.com/FasterXML/jackson-dataformat-yaml
If I understand correctly, jackson-dataformat-yaml is used to convert YAML to JSON. toml4j doesn't convert TOML to JSON. Is that the feature you're asking for?
Could the equivalent to com.fasterxml.jackson.dataformat.yaml.YAMLFactory be in a different project? I would prefer that solution. Calling Toml#toMap() and then using a JSON library to convert the Map to JSON seems easy enough to me and has the advantage of being library-agnostic. So I'd like to keep it out of the core.
IMHO, yes, a seperate module is the way to go. I belive usually when people thin of a 'jackson module' its not quite about conversion to/from JSON, rather its integration to the jackson module system so that the full API's work (format agnostic). Every module does this a bit differently, sometimes vastly differently -- (I wish one coulud just pass a filename or mime-type to jackson and 'it worked' -- but not quite.)
Q: are there TOML constructs that do not map to JSON well? (tables?) A test of that is if a round-trip conversion from TOML->JSON->TOML preserves all 'important' data.
If the TOML data model is round-trippable to JSON then yes it should be fairly easy -- although a general purpose jackson dataformat module need do a little more than just convert to map ...
Thanks for that explanation, @DALDEI . I really don't know very much about Jackson or it's module system, so I'm not sure what making "the full APIs work" really means, or how much work it would be.