Add support for full BMC FW flash image

Add BMC flash file name list for full flash image.
Save the information for which images are being updated.

Tested: Update '.static.mtd.all.tar' with redfish API (
        UpdateService.SimpleUpdate).
        Verified the code update works well.

Change-Id: Icb47e518db61a8d17998179aed328d0cf56db6f5
Signed-off-by: Bright Cheng <bright_cheng@wiwynn.com>
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
diff --git a/item_updater.hpp b/item_updater.hpp
index b1d1c63..721d371 100644
--- a/item_updater.hpp
+++ b/item_updater.hpp
@@ -11,6 +11,7 @@
 #include <xyz/openbmc_project/Control/FieldMode/server.hpp>
 
 #include <string>
+#include <vector>
 
 namespace phosphor
 {
@@ -161,6 +162,9 @@
      * version id */
     std::map<std::string, std::unique_ptr<VersionClass>> versions;
 
+    /** @brief Vector of needed BMC images in the tarball*/
+    std::vector<std::string> imageUpdateList;
+
   private:
     /** @brief Callback function for Software.Version match.
      *  @details Creates an Activation D-Bus object.
@@ -238,6 +242,17 @@
      *  alternate chip.
      */
     void mirrorUbootToAlt();
+
+    /** @brief Check the required image files
+     *
+     * @param[in] filePath - BMC tarball file path
+     * @param[in] imageList - Image filenames included in the BMC tarball
+     * @param[out] result - Boolean
+     *                      true if all image files are found in BMC tarball
+     *                      false if one of image files is missing
+     */
+    bool checkImage(const std::string& filePath,
+                    const std::vector<std::string>& imageList);
 };
 
 } // namespace updater