diff options
Diffstat (limited to 'libs')
-rw-r--r-- | libs/__init__.py | 1 | ||||
-rw-r--r-- | libs/json_tools.py | 6 |
2 files changed, 7 insertions, 0 deletions
diff --git a/libs/__init__.py b/libs/__init__.py new file mode 100644 index 0000000..5e2ded0 --- /dev/null +++ b/libs/__init__.py @@ -0,0 +1 @@ +from json_tools import JsonSerializable
\ No newline at end of file diff --git a/libs/json_tools.py b/libs/json_tools.py new file mode 100644 index 0000000..6354531 --- /dev/null +++ b/libs/json_tools.py @@ -0,0 +1,6 @@ +import json + + +class JsonSerializable(object): + def __repr__(self): + return json.dumps(self.__dict__) |