From 88d2877ffa1ebf4e24e0c366ff5fdce8ba37739b Mon Sep 17 00:00:00 2001 From: Nikita Chernyadev Date: Thu, 4 Apr 2024 20:46:33 +0100 Subject: [PATCH] Rename store to add --- mojo/elements/utils.py | 2 +- mojo/mojo.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mojo/elements/utils.py b/mojo/elements/utils.py index 79ee67f..97f7e1a 100644 --- a/mojo/elements/utils.py +++ b/mojo/elements/utils.py @@ -96,7 +96,7 @@ def remove(self, path: str) -> None: asset = self._store.pop(path) self._unload_asset(asset) - def store(self, path: str, asset_mjcf: mjcf.Element) -> None: + def add(self, path: str, asset_mjcf: mjcf.Element) -> None: """Add new MJCF asset.""" self._store[path] = asset_mjcf if self._capacity and len(self._store) > self._capacity: diff --git a/mojo/mojo.py b/mojo/mojo.py index a6d7641..cffa845 100644 --- a/mojo/mojo.py +++ b/mojo/mojo.py @@ -95,13 +95,13 @@ def get_material(self, path: str) -> Optional[mjcf.Element]: return self._texture_store.get(path) def store_material(self, path: str, material_mjcf: mjcf.Element) -> None: - self._texture_store.store(path, material_mjcf) + self._texture_store.add(path, material_mjcf) def get_mesh(self, path: str) -> Optional[mjcf.Element]: return self._mesh_store.get(path) def store_mesh(self, path: str, mesh_mjcf: mjcf.Element) -> None: - self._mesh_store.store(path, mesh_mjcf) + self._mesh_store.add(path, mesh_mjcf) def load_model( self,