control: Create config key check function

Move the configuration/profile check to include groups into events to a
function that can be used by other configurations that also need to do
this check. Update the check to include a fan within a zone to use this
function.

Change-Id: I71259ce0fcd61917a5d7a5bb9ac2d1906130389e
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
diff --git a/control/json/manager.hpp b/control/json/manager.hpp
index 8ac48d1..d6a4499 100644
--- a/control/json/manager.hpp
+++ b/control/json/manager.hpp
@@ -168,6 +168,17 @@
     }
 
     /**
+     * @brief Check if the given input configuration key matches with another
+     * configuration key that it's to be included in
+     *
+     * @param[in] input - Config key to be included in another config object
+     * @param[in] comp - Config key of the config object to compare with
+     *
+     * @return Whether the configuration object should be included
+     */
+    static bool inConfig(const configKey& input, const configKey& comp);
+
+    /**
      * @brief Check if the given path and inteface is owned by a dbus service
      *
      * @param[in] path - Dbus object path