convertPreprocessorToJson function

Convert the persistent aspects of a covariate preprocessor to (in-memory) C++ JSON object