From dfd185135277441cff347b9bc38e8248b219087b Mon Sep 17 00:00:00 2001
From: Rainer Kartmann <rainer.kartmann@kit.edu>
Date: Tue, 22 Jun 2021 13:51:19 +0200
Subject: [PATCH] Update usages

---
 .../armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp  | 4 ++--
 source/RobotAPI/libraries/armem/client/util/MemoryListener.h  | 2 +-
 .../armem_objects/client/articulated_object/Reader.cpp        | 2 +-
 .../armem_objects/client/articulated_object/Writer.cpp        | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp b/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
index 6ad1e88da..8ae42e00b 100644
--- a/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
+++ b/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
@@ -92,12 +92,12 @@ namespace armarx
 
         // Subscribe to example_entity updates
         // Using a lambda:
-        memoryReader.subscribe(exampleEntityID, [&](const armem::MemoryID & exampleEntityID, const std::vector<armem::MemoryID>& snapshotIDs)
+        memoryNameSystem.subscribe(exampleEntityID, [&](const armem::MemoryID & exampleEntityID, const std::vector<armem::MemoryID>& snapshotIDs)
         {
             ARMARX_INFO << "Entity " << exampleEntityID << " was updated by " << snapshotIDs.size() << " snapshots.";
         });
         // Using a member function:
-        memoryReader.subscribe(exampleEntityID, this, &ExampleMemoryClient::processExampleEntityUpdate);
+        memoryNameSystem.subscribe(exampleEntityID, this, &ExampleMemoryClient::processExampleEntityUpdate);
 
 
         task = new RunningTask<ExampleMemoryClient>(this, &ExampleMemoryClient::run);
diff --git a/source/RobotAPI/libraries/armem/client/util/MemoryListener.h b/source/RobotAPI/libraries/armem/client/util/MemoryListener.h
index 33e1e1042..e412bfefc 100644
--- a/source/RobotAPI/libraries/armem/client/util/MemoryListener.h
+++ b/source/RobotAPI/libraries/armem/client/util/MemoryListener.h
@@ -41,7 +41,7 @@ namespace armarx::armem::client::util
         /**
          * Subscribe with a class member function:
          * @code
-         * reader.subscribe(entityID, this, &This::myCallback);
+         * listener.subscribe(entityID, this, &This::myCallback);
          * @endcode
          */
         template <class CalleeT>
diff --git a/source/RobotAPI/libraries/armem_objects/client/articulated_object/Reader.cpp b/source/RobotAPI/libraries/armem_objects/client/articulated_object/Reader.cpp
index f7ba4898f..8824b1e7f 100644
--- a/source/RobotAPI/libraries/armem_objects/client/articulated_object/Reader.cpp
+++ b/source/RobotAPI/libraries/armem_objects/client/articulated_object/Reader.cpp
@@ -60,7 +60,7 @@ namespace armarx::armem::articulated_object
         id.coreSegmentName = properties.coreClassSegmentName;
         // listen to all provider segments!
 
-        memoryReader.subscribe(id, this, &Reader::updateKnownObjects);
+        memoryNameSystem.subscribe(id, this, &Reader::updateKnownObjects);
     }
 
     void Reader::updateKnownObject(const armem::MemoryID& snapshotId)
diff --git a/source/RobotAPI/libraries/armem_objects/client/articulated_object/Writer.cpp b/source/RobotAPI/libraries/armem_objects/client/articulated_object/Writer.cpp
index f89283202..f351382f3 100644
--- a/source/RobotAPI/libraries/armem_objects/client/articulated_object/Writer.cpp
+++ b/source/RobotAPI/libraries/armem_objects/client/articulated_object/Writer.cpp
@@ -70,7 +70,7 @@ namespace armarx::armem::articulated_object
         id.setCoreSegmentID(refId); // listen to all provider segments!
 
         updateKnownObjects();
-        memoryReader.subscribe(id, this, &Writer::updateKnownObjects);
+        memoryNameSystem.subscribe(id, this, &Writer::updateKnownObjects);
     }
 
     void Writer::updateKnownObject(const armem::MemoryID& snapshotId)
-- 
GitLab