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

Unified Diff: chrome/browser/chromeos/cros/network_ip_config.cc

Issue 11756002: Move cros_network_functions.cc to src/chromeos (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Clang fixes Created 7 years, 12 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chromeos/cros/network_ip_config.h ('k') | chrome/browser/chromeos/cros/network_library.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/cros/network_ip_config.cc
diff --git a/chrome/browser/chromeos/cros/network_ip_config.cc b/chrome/browser/chromeos/cros/network_ip_config.cc
deleted file mode 100644
index 4dd105e0f369a319a5fe08946193c6458099e930..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/cros/network_ip_config.cc
+++ /dev/null
@@ -1,53 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "chrome/browser/chromeos/cros/network_ip_config.h"
-
-#include "base/logging.h"
-
-namespace chromeos {
-
-namespace {
-#define ENUM_CASE(x) case x: return std::string(#x)
-std::string IPConfigTypeAsString(IPConfigType type) {
- switch (type) {
- ENUM_CASE(IPCONFIG_TYPE_UNKNOWN);
- ENUM_CASE(IPCONFIG_TYPE_IPV4);
- ENUM_CASE(IPCONFIG_TYPE_IPV6);
- ENUM_CASE(IPCONFIG_TYPE_DHCP);
- ENUM_CASE(IPCONFIG_TYPE_BOOTP);
- ENUM_CASE(IPCONFIG_TYPE_ZEROCONF);
- ENUM_CASE(IPCONFIG_TYPE_DHCP6);
- ENUM_CASE(IPCONFIG_TYPE_PPP);
- }
- NOTREACHED() << "Unhandled enum value " << type;
- return std::string();
-}
-#undef ENUM_CASE
-} // namespace
-
-NetworkIPConfig::NetworkIPConfig(
- const std::string& device_path, IPConfigType type,
- const std::string& address, const std::string& netmask,
- const std::string& gateway, const std::string& name_servers)
- : device_path(device_path),
- type(type),
- address(address),
- netmask(netmask),
- gateway(gateway),
- name_servers(name_servers) {
-}
-
-NetworkIPConfig::~NetworkIPConfig() {}
-
-std::string NetworkIPConfig::ToString() const {
- return std::string("path: ") + device_path
- + " type: " + IPConfigTypeAsString(type)
- + " address: " + address
- + " netmask: " + netmask
- + " gateway: " + gateway
- + " name_servers: " + name_servers;
-}
-
-} // namespace chromeos
« no previous file with comments | « chrome/browser/chromeos/cros/network_ip_config.h ('k') | chrome/browser/chromeos/cros/network_library.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698