Reorganize code into multiple files and classes
This is a major refactoring of the code:
- Split the code over multiple files with one file per format and compression method
- Use class based dynamic dispatch on the format and compression method
These additional changes are included as well
- Use automatic json/enum conversion
- Ensure that no exceptions leak to the caller of the API function
Edited by Tim Schoof