Add {Get,Set}CohortHint interface.
Export the "cohort hint" getter and setter in the client interfaces
(D-Bus and Binder). The cohort hint is sent to Omaha on every update
check request but can be ignored and/or reset by Omaha on every
response.
Other minor linter fixes to the affected files.
Bug: 31740109
Test: Build with D-Bus and with Binder.
Change-Id: I93214f6ffb8662c238b3351e52bf2bdf23e46a9c
diff --git a/client_library/client_dbus.cc b/client_library/client_dbus.cc
index 5cb63a4..426412c 100644
--- a/client_library/client_dbus.cc
+++ b/client_library/client_dbus.cc
@@ -72,6 +72,14 @@
return StringToUpdateStatus(status_as_string, out_update_status);
}
+bool DBusUpdateEngineClient::SetCohortHint(const string& cohort_hint) {
+ return proxy_->SetCohortHint(cohort_hint, nullptr);
+}
+
+bool DBusUpdateEngineClient::GetCohortHint(string* cohort_hint) const {
+ return proxy_->GetCohortHint(cohort_hint, nullptr);
+}
+
bool DBusUpdateEngineClient::SetUpdateOverCellularPermission(bool allowed) {
return proxy_->SetUpdateOverCellularPermission(allowed, nullptr);
}