Reputation: 3096
I'd like to generate XML picklers for an XSD file. It seems like a useful tool that might already exist. Does it?
Upvotes: 5
Views: 1243
Reputation: 38891
HaXml
does have a tool for generating Haskell data types from DTDs and a tool for generating Haskell data types from XSDs: http://hackage.haskell.org/package/HaXml
The executables are named XsdToHaskell and DtdToHaskell.
If you're on Windows and you have PATH modified by Haskell Platform, you'll need to call it like this: xsdtohaskell < path_to.xsd > path_to.hs
The generated files are a decent starting point.
Upvotes: 2