| Index: chromeos/network/network_state.h
|
| diff --git a/chromeos/network/network_state.h b/chromeos/network/network_state.h
|
| index 995982417ec37faa1b87131ce118b853576451c1..d43def68b30af8dbca3e37a8db5f7f3672e7e18c 100644
|
| --- a/chromeos/network/network_state.h
|
| +++ b/chromeos/network/network_state.h
|
| @@ -5,6 +5,9 @@
|
| #ifndef CHROMEOS_NETWORK_NETWORK_STATE_H_
|
| #define CHROMEOS_NETWORK_NETWORK_STATE_H_
|
|
|
| +#include <string>
|
| +#include <vector>
|
| +
|
| #include "chromeos/network/managed_state.h"
|
|
|
| namespace base {
|
| @@ -36,6 +39,7 @@ class CHROMEOS_EXPORT NetworkState : public ManagedState {
|
| // Accessors
|
| const std::string& security() const { return security_; }
|
| const std::string& ip_address() const { return ip_address_; }
|
| + const std::vector<std::string>& dns_servers() const { return dns_servers_; }
|
| const std::string& device_path() const { return device_path_; }
|
| const std::string& guid() const { return guid_; }
|
| const std::string& connection_state() const { return connection_state_; }
|
| @@ -61,6 +65,10 @@ class CHROMEOS_EXPORT NetworkState : public ManagedState {
|
| static bool StateIsConnected(const std::string& connection_state);
|
| static bool StateIsConnecting(const std::string& connection_state);
|
|
|
| + // Helper to return a full prefixed version of an IPConfig property
|
| + // key.
|
| + static std::string IPConfigProperty(const char* key);
|
| +
|
| private:
|
| friend class NetworkStateHandler;
|
| friend class NetworkChangeNotifierChromeosUpdateTest;
|
| @@ -69,17 +77,24 @@ class CHROMEOS_EXPORT NetworkState : public ManagedState {
|
| void set_ip_address(const std::string& ip_address) {
|
| ip_address_ = ip_address;
|
| }
|
| + void set_dns_servers(const std::vector<std::string>& dns_servers) {
|
| + dns_servers_ = dns_servers;
|
| + }
|
|
|
| // Common Network Service properties
|
| std::string security_;
|
| std::string device_path_;
|
| std::string guid_;
|
| - std::string ip_address_;
|
| std::string connection_state_;
|
| std::string error_;
|
| bool auto_connect_;
|
| bool favorite_;
|
| int priority_;
|
| + // IPConfig properties.
|
| + // Note: These do not correspond to actual Shill.Service properties
|
| + // but are derived from the service's corresponding IPConfig object.
|
| + std::string ip_address_;
|
| + std::vector<std::string> dns_servers_;
|
| // Wireless properties
|
| int signal_strength_;
|
| // Cellular properties
|
|
|