Create Activation dbus object
Monitor the creation of new software version dbus objects and
create an activation dbus object SOFTWARE_OBJPATH/<ID>.
Save them in a persistent map with the corresponding version id,
add the real version id number to the map and to the dbus
object path once that's available.
Change-Id: I35c2f211bbefc44a066aafa1760f725399215e69
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
diff --git a/item_updater.cpp b/item_updater.cpp
new file mode 100755
index 0000000..9614f50
--- /dev/null
+++ b/item_updater.cpp
@@ -0,0 +1,28 @@
+#include "config.h"
+#include "item_updater.hpp"
+
+namespace openpower
+{
+namespace software
+{
+namespace manager
+{
+
+int ItemUpdater::createActivation(sd_bus_message* msg,
+ void* userData,
+ sd_bus_error* retErr)
+{
+ auto versionId = 1;
+ auto* updater = static_cast<ItemUpdater*>(userData);
+ updater->activations.insert(std::make_pair(
+ versionId,
+ std::make_unique<Activation>(
+ updater->busItem,
+ SOFTWARE_OBJPATH)));
+ return 0;
+}
+
+} // namespace manager
+} // namespace software
+} // namespace openpower
+