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

Unified Diff: chromeos/network/onc/onc_signature.cc

Issue 11414101: This adds ManagedNetworkConfigurationHandler first pass (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: upload after merge Created 7 years, 11 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 | « chromeos/network/onc/onc_signature.h ('k') | chromeos/network/onc/onc_translator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/network/onc/onc_signature.cc
diff --git a/chromeos/network/onc/onc_signature.cc b/chromeos/network/onc/onc_signature.cc
index 942fbdaaf0160fd0a2d296c8ec03b0f62c91464f..ba5315476c0758e8c2e51b1278e534034dcf045d 100644
--- a/chromeos/network/onc/onc_signature.cc
+++ b/chromeos/network/onc/onc_signature.cc
@@ -386,8 +386,9 @@ const OncValueSignature kToplevelConfigurationSignature = {
Value::TYPE_DICTIONARY, toplevel_configuration_fields, NULL
};
-const OncFieldSignature* GetFieldSignature(const OncValueSignature& signature,
- const std::string& onc_field_name) {
+const OncFieldSignature* GetOncFieldSignature(
+ const OncValueSignature& signature,
+ const std::string& onc_field_name) {
if (!signature.fields)
return NULL;
for (const OncFieldSignature* field_signature = signature.fields;
@@ -398,5 +399,19 @@ const OncFieldSignature* GetFieldSignature(const OncValueSignature& signature,
return NULL;
}
+const OncFieldSignature* GetShillFieldSignature(
+ const OncValueSignature& signature,
+ const std::string& shill_property_name) {
+ if (!signature.fields)
+ return NULL;
+ for (const OncFieldSignature* field_signature = signature.fields;
+ field_signature->onc_field_name != NULL; ++field_signature) {
+ if (shill_property_name == field_signature->shill_property_name)
+ return field_signature;
+ }
+ return NULL;
+}
+
+
} // namespace onc
} // namespace chromeos
« no previous file with comments | « chromeos/network/onc/onc_signature.h ('k') | chromeos/network/onc/onc_translator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698