[Release] wrt-commons_0.2.119
[framework/web/wrt-commons.git] / modules / widget_dao / dao / config_parser_data.cpp
index eccbe40..4bf4857 100644 (file)
@@ -203,104 +203,34 @@ void NormalizeAndTrimSpaceString(DPL::OptionalString& txt)
     NormalizeString(txt, true);
 }
 
-bool ConfigParserData::Param::operator==(const Param& other) const
-{
-    return name == other.name && value == other.value;
-}
-
-bool ConfigParserData::Param::operator!=(const Param& other) const
-{
-    return name != other.name || value != other.value;
-}
-
-bool ConfigParserData::Param::operator >(const Param& other) const
-{
-    if (name == other.name) {
-        return value > other.value;
-    } else {
-        return name > other.name;
-    }
-}
-
-bool ConfigParserData::Param::operator>=(const Param& other) const
-{
-    if (name >= other.name) {
-        return true;
-    } else {
-        return value >= other.value;
-    }
-}
-
-bool ConfigParserData::Param::operator <(const Param& other) const
-{
-    if (name == other.name) {
-        return value < other.value;
-    } else {
-        return name < other.name;
-    }
-}
-
-bool ConfigParserData::Param::operator<=(const Param& other) const
-{
-    if (name <= other.name) {
-        return true;
-    } else {
-        return value <= other.value;
-    }
-}
-
 bool ConfigParserData::Feature::operator==(const Feature& other) const
 {
-    return name == other.name && paramsList == other.paramsList;
+    return name == other.name;
 }
 
 bool ConfigParserData::Feature::operator!=(const Feature& other) const
 {
-    return name != other.name || paramsList != other.paramsList;
+    return name != other.name;
 }
 
 bool ConfigParserData::Feature::operator >(const Feature& other) const
 {
-    if (name > other.name) {
-        return true;
-    }
-    if (name < other.name) {
-        return false;
-    }
-    return paramsList > other.paramsList;
+    return name > other.name;
 }
 
 bool ConfigParserData::Feature::operator>=(const Feature& other) const
 {
-    if (name > other.name) {
-        return true;
-    }
-    if (name < other.name) {
-        return false;
-    }
-    return paramsList >= other.paramsList;
+    return name >= other.name;
 }
 
 bool ConfigParserData::Feature::operator <(const Feature& other) const
 {
-    if (name < other.name) {
-        return true;
-    }
-    if (name > other.name) {
-        return false;
-    }
-    return paramsList < other.paramsList;
+    return name < other.name;
 }
 
 bool ConfigParserData::Feature::operator<=(const Feature& other) const
 {
-    if (name < other.name) {
-        return true;
-    }
-    if (name > other.name) {
-        return false;
-    }
-    return paramsList <= other.paramsList;
+    return name <= other.name;
 }
 
 bool ConfigParserData::Privilege::operator==(const Privilege& other) const
@@ -446,20 +376,22 @@ bool ConfigParserData::Setting::operator<=(const Setting& other) const
     return m_name <= other.m_name;
 }
 
-bool ConfigParserData::ServiceInfo::operator== (const ServiceInfo& info) const
+bool ConfigParserData::AppControlInfo::operator== (const AppControlInfo& info) const
 {
     return m_src == info.m_src &&
            m_operation == info.m_operation &&
-           m_scheme == info.m_scheme &&
-           m_mime == info.m_mime;
+           m_uriList == info.m_uriList &&
+           m_mimeList == info.m_mimeList &&
+           m_disposition == info.m_disposition;
 }
 
-bool ConfigParserData::ServiceInfo::operator!= (const ServiceInfo& info) const
+bool ConfigParserData::AppControlInfo::operator!= (const AppControlInfo& info) const
 {
-    return m_src != info.m_src &&
-           m_operation != info.m_operation &&
-           m_scheme != info.m_scheme &&
-           m_mime != info.m_mime;
+    return m_src != info.m_src ||
+           m_operation != info.m_operation ||
+           m_uriList != info.m_uriList ||
+           m_mimeList != info.m_mimeList ||
+           m_disposition != info.m_disposition;
 }
 
 bool ConfigParserData::LiveboxInfo::operator==(const LiveboxInfo& other) const
@@ -481,4 +413,14 @@ bool ConfigParserData::LiveboxInfo::operator!=(const LiveboxInfo& other) const
            m_label != other.m_label &&
            m_icon != other.m_icon;
 }
+
+bool ConfigParserData::Metadata::operator== (const Metadata& other) const
+{
+    return key == other.key && value == other.value;
+}
+
+bool ConfigParserData::Metadata::operator!= (const Metadata& other) const
+{
+    return key != other.key || value != other.value;
+}
 } // namespace WrtDB