def export_book(databook): """Returns JSON representation of Databook.""" return anyjson.serialize(databook._package())
def export_set(dataset): """Returns JSON representation of Dataset.""" return anyjson.serialize(dataset.dict)