[ANN] json_of_jsonm 1.0.0 released

announce

#1

json_of_jsonm 1.0.0 has been released. This provides a layer on top of jsonm to encode and decode text to a json type. Key features include:

  • The json type is compatible with and a subset of yojson’s json type
  • Both string and channel interfaces are provided
  • The API supports Pervasives.result and exceptions to handle errors
  • A functor is provided to implement additional I/O mechanisms. The README includes an Async example.
  • The string module defines a standard t, of_string and to_string interface

#2

Just in case anybody else wanted to know more as well, here is the repository:


#3

Would you please describe how this library differs from ezjsonm?


#4

json_of_jsonm is designed to provide a thin layer on top of jsonm that allows conversion to and from a reasonably standard json type. In addition, where appropriate, the API attempts to follow standard conventions (the string module defines a type t and {of,to}_string functions for example) and provide exception and result based eror reporting

Finally, additional I/O mechanisms can easily be defined with an example Async module shown in the examples section of the README.md

ezjsom in comparison provides a number of useful functions that extend the jsonm library as weill as adding Lwt support. However, it follows jsonm typing and does not support I/O methods other than those already provided by the library

Which you use will depend on your needs, for me json_of_jsonm is used to handle thinks like RESTful APIs using Async libraries but others may find ezsjonm’s access functions more useful.