obspy.core.json.default

JSON Encoder default function

This module provides:

Default : a class to create a “default” function accepted by the python json module Encoder classes, valid for Event objects.

Example

>>> import json
>>> from obspy import readEvents
>>> from obspy.core.json import Default
>>> c = readEvents()
>>> d = Default(omit_nulls=False)
>>> s = json.dumps(c, default=d)

Classes

Default Class to create a “default” function for the

Table Of Contents

This Page