Host updater: Add function to delete all versions

As a part of openbmc/openbmc#2264, implements a DeleteAll for all
non-functional host versions in the host updater.

Change-Id: I2943df248463ba8b4537096cf08f902d758c24a0
Signed-off-by: Michael Tritz <mtritz@us.ibm.com>
diff --git a/item_updater.hpp b/item_updater.hpp
index 5d2a15e..06e65a0 100755
--- a/item_updater.hpp
+++ b/item_updater.hpp
@@ -5,6 +5,7 @@
 #include <xyz/openbmc_project/Common/FactoryReset/server.hpp>
 #include "version.hpp"
 #include "org/openbmc/Associations/server.hpp"
+#include "xyz/openbmc_project/Collection/DeleteAll/server.hpp"
 
 namespace openpower
 {
@@ -15,7 +16,8 @@
 
 using ItemUpdaterInherit = sdbusplus::server::object::object<
     sdbusplus::xyz::openbmc_project::Common::server::FactoryReset,
-    sdbusplus::org::openbmc::server::Associations>;
+    sdbusplus::org::openbmc::server::Associations,
+    sdbusplus::xyz::openbmc_project::Collection::server::DeleteAll>;
 namespace MatchRules = sdbusplus::bus::match::rules;
 
 using AssociationList =
@@ -79,6 +81,11 @@
          */
         void erase(std::string entryId);
 
+        /**
+         * @brief Erases any non-active pnor versions.
+         */
+        void deleteAll();
+
         /** @brief Deletes the active pnor version with highest priority
                    if the total number of volume exceeds the threshold.
          */