threshold: use absolute value for D-Bus

Use the absolute value for threshold rather than percentage value.
This involves passing the total value from the metric collection so it
can be used in percentage calculation within health metric logic.

Change-Id: I46240aee54117c70637f9fbf882018f0eac520b2
Signed-off-by: Jagpal Singh Gill <paligill@gmail.com>
diff --git a/health_metric.hpp b/health_metric.hpp
index 01f6836..e79fce1 100644
--- a/health_metric.hpp
+++ b/health_metric.hpp
@@ -28,10 +28,10 @@
 
 struct MValue
 {
-    /** @brief Value for end user consumption */
-    double user;
-    /** @brief Value for threshold monitor */
-    double monitor;
+    /** @brief Current value of metric */
+    double current;
+    /** @brief Total value of metric */
+    double total;
 };
 
 class HealthMetric : public MetricIntf
@@ -61,9 +61,9 @@
     void initProperties();
     /** @brief Check specified threshold for the given value */
     void checkThreshold(ThresholdIntf::Type type, ThresholdIntf::Bound bound,
-                        double value);
+                        MValue value);
     /** @brief Check all thresholds for the given value */
-    void checkThresholds(double value);
+    void checkThresholds(MValue value);
     /** @brief Get the object path for the given subtype */
     auto getPath(SubType subType) -> std::string;
     /** @brief D-Bus bus connection */