def from_js(self, json): """Documentation""" if isinstance(json, dict): json_dict = json else: json_dict = deps.loads(json) for key, prop in self.properties().items(): value = json_dict[key] prop.from_js(value)
def from_js(self, value): return self.validate(deps.loads(value))