TorusObject.to_json

TorusObject.to_json(filepath, pretty=False)[source]

Convert an object to its native data representation and save it to a JSON file.

Parameters:
filepathstr

The path to the JSON file.

prettybool, optional

If True, the JSON file will be pretty printed. Defaults to False.