MCPcopy
hub / github.com/apache/caldera / replace_object

Method replace_object

app/api/v2/managers/base_api_manager.py:94–96  ·  view source on GitHub ↗
(self, obj: Any, data: dict)

Source from the content-addressed store, hash-verified

92 return self.replace_object(obj, data)
93
94 def replace_object(self, obj: Any, data: dict):
95 new_obj = obj.schema.load(data)
96 return new_obj.store(self._data_svc.ram)
97
98 async def find_and_update_on_disk_object(self, data: dict, search: dict, ram_key: str, id_property: str, obj_class: type):
99 for obj in self.find_objects(ram_key, search):

Callers 3

update_objectMethod · 0.95
test_replace_objectFunction · 0.95
update_objectMethod · 0.80

Calls 2

loadMethod · 0.45
storeMethod · 0.45

Tested by 1

test_replace_objectFunction · 0.76