control: Use group objects in actions

Switch to use the group objects created from JSON in the actions which
allows the zone and fan YAML objects to be removed from the JSON based
binary. In switching to the JSON based group objects, the
`default_floor` action required additional methods to be added to the
appropriate objects. These additional methods were copied over from the
associated YAML based object classes.

To reduce the amount of changes in this commit, the `requestIncrease`
method was not copied over and will be in a following commit. An
additional commit will also remove the use of YAML based objects from
the JSON based zone object.

Change-Id: I5fea29f099d0176b2ffe486e79f0c585e744d807
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
diff --git a/control/json/zone.cpp b/control/json/zone.cpp
index 11b7814..243fade 100644
--- a/control/json/zone.cpp
+++ b/control/json/zone.cpp
@@ -43,7 +43,7 @@
                                  {currentProp, zone::property::current}}}};
 
 Zone::Zone(sdbusplus::bus::bus& bus, const json& jsonObj) :
-    ConfigBase(jsonObj), _incDelay(0)
+    ConfigBase(jsonObj), _incDelay(0), _floor(0), _target(0)
 {
     if (jsonObj.contains("profiles"))
     {
@@ -72,6 +72,26 @@
     _fans.emplace_back(std::move(fan));
 }
 
+void Zone::setFloor(uint64_t target)
+{
+    // Check all entries are set to allow floor to be set
+    auto pred = [](auto const& entry) { return entry.second; };
+    if (std::all_of(_floorChange.begin(), _floorChange.end(), pred))
+    {
+        _floor = target;
+        // Floor above target, update target to floor
+        if (_target < _floor)
+        {
+            requestIncrease(_floor - _target);
+        }
+    }
+}
+
+void Zone::requestIncrease(uint64_t targetDelta)
+{
+    // TODO Add from `requestSpeedIncrease` method in YAML zone object
+}
+
 void Zone::setFullSpeed(const json& jsonObj)
 {
     if (!jsonObj.contains("full_speed"))
@@ -81,6 +101,8 @@
         throw std::runtime_error("Missing required zone's full speed");
     }
     _fullSpeed = jsonObj["full_speed"].get<uint64_t>();
+    // Start with the current target set as the default
+    _target = _fullSpeed;
 }
 
 void Zone::setDefaultFloor(const json& jsonObj)
@@ -92,6 +114,8 @@
         throw std::runtime_error("Missing required zone's default floor speed");
     }
     _defaultFloor = jsonObj["default_floor"].get<uint64_t>();
+    // Start with the current floor set as the default
+    _floor = _defaultFloor;
 }
 
 void Zone::setDecInterval(const json& jsonObj)