simple generic support for converting json (or xml) values to haskell objects