def save_data (self, filepath):
json.dump (self.data, file (filepath, "w"), indent=4)
+ # load the data from a file
+ def load_data (self, filepath):
+ self.data = json.load (file (filepath, "rb"))
+
# set the document title
def set_document_title (self, title):
self.data["title"] = title