add class to serialize objects of OpenStruct to json string