Un-expanded to expanded location code conversion

This commit implements an api to get expanded location code
from a given un-expanded location code and node number.

In case invalid argument is passed or the location code is
not found, corresponding error is returned to the caller.

Tested on simics.

To build use following command.
meson -Dibm-parser=enabled -Dvpd-manager=enabled build
ninja -C build

Sample bus call.
busctl call com.ibm.VPD.Manager /com/ibm/VPD/Manager com.ibm.VPD.Manager
GetExpandedLocationCode sq <locationCode> <nodeNumber>.

Signed-off-by: SunnySrivastava1984 <sunnsr25@in.ibm.com>
Change-Id: I52654a1c34d25dc9b861159a2ae1d15379b44677
diff --git a/vpd-manager/reader_impl.hpp b/vpd-manager/reader_impl.hpp
index d9ceafe..17cfc75 100644
--- a/vpd-manager/reader_impl.hpp
+++ b/vpd-manager/reader_impl.hpp
@@ -1,5 +1,7 @@
 #pragma once
 
+#include "types.hpp"
+
 namespace openpower
 {
 namespace vpd
@@ -12,8 +14,6 @@
 /** @class ReaderImpl
  *  @brief Implements functionalities related to reading of VPD related data
  *  from the system.
- *
- *  A parsed vpd inventory json file is required to construct the class.
  */
 class ReaderImpl
 {
@@ -24,6 +24,18 @@
     ReaderImpl(ReaderImpl&&) = delete;
     ReaderImpl& operator=(ReaderImpl&&) = delete;
     ~ReaderImpl() = default;
+
+    /** @brief An API to expand a given unexpanded location code.
+     *  @param[in] locationCode - unexpanded location code.
+     *  @param[in] nodeNumber - node on which we are looking for location code.
+     *  @param[in] frusLocationCode - mapping of inventory path and location
+     * code.
+     *  @return Expanded location code.
+     */
+    std::string getExpandedLocationCode(
+        const std::string& locationCode, const uint16_t& nodeNumber,
+        const inventory::LocationCodeMap& frusLocationCode) const;
+
 }; // class ReaderImpl
 
 } // namespace reader