PolicyManager: Mark protected members as private.
The Google C++ style guide requires members to be private having
a getter and setter with fixed names. This patch moves the protected
members to the private section on the base class for each provider
and adds a protected setter to allow the sub-classes to set these
members on Init().
Also, this patch uniforms the variable names prefixing them with
var_.
BUG=None
TEST=Unit tests still passes.
Change-Id: I4cbf7b7031b430991c12a5c7d9729bafaf359095
Reviewed-on: https://chromium-review.googlesource.com/187979
Reviewed-by: Gilad Arnold <garnold@chromium.org>
Tested-by: Alex Deymo <deymo@chromium.org>
Commit-Queue: Alex Deymo <deymo@chromium.org>
diff --git a/policy_manager/fake_shill_provider.h b/policy_manager/fake_shill_provider.h
index 65ddf38..f75ef2c 100644
--- a/policy_manager/fake_shill_provider.h
+++ b/policy_manager/fake_shill_provider.h
@@ -17,11 +17,11 @@
protected:
virtual bool DoInit() {
- var_is_connected_.reset(
+ set_var_is_connected(
new FakeVariable<bool>("is_connected", kVariableModeAsync));
- var_conn_type_.reset(
+ set_var_conn_type(
new FakeVariable<ShillConnType>("conn_type", kVariableModeAsync));
- var_conn_last_changed_.reset(
+ set_var_conn_last_changed(
new FakeVariable<Time>("conn_last_changed", kVariableModeAsync));
return true;
}