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

Side by Side Diff: chromeos/network/onc/onc_translation_tables.cc

Issue 552113002: Add ONC 'Source' configuration property (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue_279351_internet_options_9a
Patch Set: Rebase Created 6 years, 3 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
« no previous file with comments | « chromeos/network/onc/onc_signature.cc ('k') | chromeos/network/onc/onc_translator.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/onc/onc_translation_tables.h" 5 #include "chromeos/network/onc/onc_translation_tables.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "components/onc/onc_constants.h" 10 #include "components/onc/onc_constants.h"
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 171
172 // Type is converted during translation, see onc_translator_*. 172 // Type is converted during translation, see onc_translator_*.
173 // { ::onc::network_config::kType, shill::kTypeProperty }, 173 // { ::onc::network_config::kType, shill::kTypeProperty },
174 174
175 // These fields are converted during translation, see 175 // These fields are converted during translation, see
176 // onc_translator_shill_to_onc.cc. They are only converted when going from 176 // onc_translator_shill_to_onc.cc. They are only converted when going from
177 // Shill->ONC, and ignored otherwise. 177 // Shill->ONC, and ignored otherwise.
178 // { ::onc::network_config::kConnectionState, shill::kStateProperty }, 178 // { ::onc::network_config::kConnectionState, shill::kStateProperty },
179 // { ::onc::network_config::kRestrictedConnectivity, 179 // { ::onc::network_config::kRestrictedConnectivity,
180 // shill::kStateProperty }, 180 // shill::kStateProperty },
181 // { ::onc::network_config::kSource, shill::kProfileProperty },
181 // { ::onc::network_config::kMacAddress, shill::kAddressProperty }, 182 // { ::onc::network_config::kMacAddress, shill::kAddressProperty },
182 {NULL}}; 183 {NULL}};
183 184
184 const FieldTranslationEntry ipconfig_fields[] = { 185 const FieldTranslationEntry ipconfig_fields[] = {
185 { ::onc::ipconfig::kIPAddress, shill::kAddressProperty}, 186 { ::onc::ipconfig::kIPAddress, shill::kAddressProperty},
186 { ::onc::ipconfig::kGateway, shill::kGatewayProperty}, 187 { ::onc::ipconfig::kGateway, shill::kGatewayProperty},
187 { ::onc::ipconfig::kRoutingPrefix, shill::kPrefixlenProperty}, 188 { ::onc::ipconfig::kRoutingPrefix, shill::kPrefixlenProperty},
188 { ::onc::ipconfig::kNameServers, shill::kNameServersProperty}, 189 { ::onc::ipconfig::kNameServers, shill::kNameServersProperty},
189 // This field is converted during translation, see ShillToONCTranslator:: 190 // This field is converted during translation, see ShillToONCTranslator::
190 // TranslateIPConfig. It is only converted from Shill->ONC. 191 // TranslateIPConfig. It is only converted from Shill->ONC.
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
405 continue; 406 continue;
406 *onc_value = table[i].onc_value; 407 *onc_value = table[i].onc_value;
407 return true; 408 return true;
408 } 409 }
409 LOG(ERROR) << "Value '" << shill_value << "' cannot be translated to ONC"; 410 LOG(ERROR) << "Value '" << shill_value << "' cannot be translated to ONC";
410 return false; 411 return false;
411 } 412 }
412 413
413 } // namespace onc 414 } // namespace onc
414 } // namespace chromeos 415 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/onc/onc_signature.cc ('k') | chromeos/network/onc/onc_translator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698