OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 }; | 54 }; |
55 | 55 |
56 // This is the network parser that parses the data from the network | 56 // This is the network parser that parses the data from the network |
57 // stack on the native platform. Currently it parses | 57 // stack on the native platform. Currently it parses |
58 // FlimFlam-provided information. | 58 // FlimFlam-provided information. |
59 class NativeNetworkParser : public NetworkParser { | 59 class NativeNetworkParser : public NetworkParser { |
60 public: | 60 public: |
61 NativeNetworkParser(); | 61 NativeNetworkParser(); |
62 virtual ~NativeNetworkParser(); | 62 virtual ~NativeNetworkParser(); |
63 static const EnumMapper<PropertyIndex>* property_mapper(); | 63 static const EnumMapper<PropertyIndex>* property_mapper(); |
| 64 static const EnumMapper<ConnectionType>* network_type_mapper(); |
| 65 static const EnumMapper<ConnectionSecurity>* network_security_mapper(); |
| 66 static const EnumMapper<EAPMethod>* network_eap_method_mapper(); |
| 67 static const EnumMapper<EAPPhase2Auth>* network_eap_auth_mapper(); |
64 static const ConnectionType ParseConnectionType(const std::string& type); | 68 static const ConnectionType ParseConnectionType(const std::string& type); |
65 protected: | 69 protected: |
66 virtual Network* CreateNewNetwork(ConnectionType type, | 70 virtual Network* CreateNewNetwork(ConnectionType type, |
67 const std::string& service_path) OVERRIDE; | 71 const std::string& service_path) OVERRIDE; |
68 virtual bool ParseValue(PropertyIndex index, | 72 virtual bool ParseValue(PropertyIndex index, |
69 const base::Value& value, | 73 const base::Value& value, |
70 Network* network) OVERRIDE; | 74 Network* network) OVERRIDE; |
71 virtual ConnectionType ParseType(const std::string& type) OVERRIDE; | 75 virtual ConnectionType ParseType(const std::string& type) OVERRIDE; |
72 virtual ConnectionType ParseTypeFromDictionary( | 76 virtual ConnectionType ParseTypeFromDictionary( |
73 const base::DictionaryValue& info) OVERRIDE; | 77 const base::DictionaryValue& info) OVERRIDE; |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 VirtualNetwork* network); | 154 VirtualNetwork* network); |
151 ProviderType ParseProviderType(const std::string& type); | 155 ProviderType ParseProviderType(const std::string& type); |
152 private: | 156 private: |
153 DISALLOW_COPY_AND_ASSIGN(NativeVirtualNetworkParser); | 157 DISALLOW_COPY_AND_ASSIGN(NativeVirtualNetworkParser); |
154 }; | 158 }; |
155 | 159 |
156 | 160 |
157 } // namespace chromeos | 161 } // namespace chromeos |
158 | 162 |
159 #endif // CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ | 163 #endif // CHROME_BROWSER_CHROMEOS_CROS_NATIVE_NETWORK_PARSER_H_ |
OLD | NEW |