OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chromeos/network/network_util.h" | 5 #include "chromeos/network/network_util.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
(...skipping 11 matching lines...) Expand all Loading... |
22 #include "third_party/cros_system_api/dbus/service_constants.h" | 22 #include "third_party/cros_system_api/dbus/service_constants.h" |
23 | 23 |
24 namespace chromeos { | 24 namespace chromeos { |
25 | 25 |
26 WifiAccessPoint::WifiAccessPoint() | 26 WifiAccessPoint::WifiAccessPoint() |
27 : signal_strength(0), | 27 : signal_strength(0), |
28 signal_to_noise(0), | 28 signal_to_noise(0), |
29 channel(0) { | 29 channel(0) { |
30 } | 30 } |
31 | 31 |
| 32 WifiAccessPoint::WifiAccessPoint(const WifiAccessPoint& other) = default; |
| 33 |
32 WifiAccessPoint::~WifiAccessPoint() { | 34 WifiAccessPoint::~WifiAccessPoint() { |
33 } | 35 } |
34 | 36 |
35 CellularScanResult::CellularScanResult() { | 37 CellularScanResult::CellularScanResult() { |
36 } | 38 } |
37 | 39 |
| 40 CellularScanResult::CellularScanResult(const CellularScanResult& other) = |
| 41 default; |
| 42 |
38 CellularScanResult::~CellularScanResult() { | 43 CellularScanResult::~CellularScanResult() { |
39 } | 44 } |
40 | 45 |
41 namespace network_util { | 46 namespace network_util { |
42 | 47 |
43 std::string PrefixLengthToNetmask(int32_t prefix_length) { | 48 std::string PrefixLengthToNetmask(int32_t prefix_length) { |
44 std::string netmask; | 49 std::string netmask; |
45 // Return the empty string for invalid inputs. | 50 // Return the empty string for invalid inputs. |
46 if (prefix_length < 0 || prefix_length > 32) | 51 if (prefix_length < 0 || prefix_length > 32) |
47 return netmask; | 52 return netmask; |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 std::string TranslateShillTypeToONC(const std::string& shill_type) { | 220 std::string TranslateShillTypeToONC(const std::string& shill_type) { |
216 if (shill_type == shill::kTypeEthernet) | 221 if (shill_type == shill::kTypeEthernet) |
217 return ::onc::network_type::kEthernet; | 222 return ::onc::network_type::kEthernet; |
218 std::string onc_type; | 223 std::string onc_type; |
219 onc::TranslateStringToONC(onc::kNetworkTypeTable, shill_type, &onc_type); | 224 onc::TranslateStringToONC(onc::kNetworkTypeTable, shill_type, &onc_type); |
220 return onc_type; | 225 return onc_type; |
221 } | 226 } |
222 | 227 |
223 } // namespace network_util | 228 } // namespace network_util |
224 } // namespace chromeos | 229 } // namespace chromeos |
OLD | NEW |