Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(561)

Side by Side Diff: chromeos/network/network_state.cc

Issue 300623008: Move NetworkTypePattern to its own file (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_state.h" 5 #include "chromeos/network/network_state.h"
6 6
7 #include "base/strings/stringprintf.h" 7 #include "base/strings/stringprintf.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chromeos/network/network_event_log.h" 9 #include "chromeos/network/network_event_log.h"
10 #include "chromeos/network/network_profile_handler.h" 10 #include "chromeos/network/network_profile_handler.h"
11 #include "chromeos/network/network_type_pattern.h"
11 #include "chromeos/network/network_util.h" 12 #include "chromeos/network/network_util.h"
12 #include "chromeos/network/shill_property_util.h" 13 #include "chromeos/network/shill_property_util.h"
13 #include "third_party/cros_system_api/dbus/service_constants.h" 14 #include "third_party/cros_system_api/dbus/service_constants.h"
14 15
15 namespace { 16 namespace {
16 17
17 const char kErrorUnknown[] = "Unknown"; 18 const char kErrorUnknown[] = "Unknown";
18 19
19 bool ConvertListValueToStringVector(const base::ListValue& string_list, 20 bool ConvertListValueToStringVector(const base::ListValue& string_list,
20 std::vector<std::string>* result) { 21 std::vector<std::string>* result) {
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 connection_state == shill::kStateCarrier); 291 connection_state == shill::kStateCarrier);
291 } 292 }
292 293
293 // static 294 // static
294 bool NetworkState::ErrorIsValid(const std::string& error) { 295 bool NetworkState::ErrorIsValid(const std::string& error) {
295 // Shill uses "Unknown" to indicate an unset or cleared error state. 296 // Shill uses "Unknown" to indicate an unset or cleared error state.
296 return !error.empty() && error != kErrorUnknown; 297 return !error.empty() && error != kErrorUnknown;
297 } 298 }
298 299
299 } // namespace chromeos 300 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/network_device_handler_impl.cc ('k') | chromeos/network/network_state_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698