OLD | NEW |
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 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ |
6 #define CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ | 6 #define CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
485 virtual void EraseCredentials(); | 485 virtual void EraseCredentials(); |
486 | 486 |
487 // Calculate a unique identifier for the network. | 487 // Calculate a unique identifier for the network. |
488 virtual void CalculateUniqueId(); | 488 virtual void CalculateUniqueId(); |
489 | 489 |
490 // Methods to asynchronously set network service properties | 490 // Methods to asynchronously set network service properties |
491 virtual void SetStringProperty(const char* prop, const std::string& str, | 491 virtual void SetStringProperty(const char* prop, const std::string& str, |
492 std::string* dest); | 492 std::string* dest); |
493 virtual void SetBooleanProperty(const char* prop, bool b, bool* dest); | 493 virtual void SetBooleanProperty(const char* prop, bool b, bool* dest); |
494 virtual void SetIntegerProperty(const char* prop, int i, int* dest); | 494 virtual void SetIntegerProperty(const char* prop, int i, int* dest); |
495 virtual void SetValueProperty(const char* prop, base::Value* val); | 495 virtual void SetValueProperty(const char* prop, const base::Value& val); |
496 virtual void ClearProperty(const char* prop); | 496 virtual void ClearProperty(const char* prop); |
497 | 497 |
498 // This will clear the property if string is empty. Otherwise, it will set it. | 498 // This will clear the property if string is empty. Otherwise, it will set it. |
499 virtual void SetOrClearStringProperty(const char* prop, | 499 virtual void SetOrClearStringProperty(const char* prop, |
500 const std::string& str, | 500 const std::string& str, |
501 std::string* dest); | 501 std::string* dest); |
502 | 502 |
503 void set_unique_id(const std::string& unique_id) { unique_id_ = unique_id; } | 503 void set_unique_id(const std::string& unique_id) { unique_id_ = unique_id; } |
504 const CertificatePattern& client_cert_pattern() const { | 504 const CertificatePattern& client_cert_pattern() const { |
505 return ui_data_.certificate_pattern(); | 505 return ui_data_.certificate_pattern(); |
(...skipping 1240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1746 const std::string& service_path) = 0; | 1746 const std::string& service_path) = 0; |
1747 | 1747 |
1748 // Factory function, creates a new instance and returns ownership. | 1748 // Factory function, creates a new instance and returns ownership. |
1749 // For normal usage, access the singleton via CrosLibrary::Get(). | 1749 // For normal usage, access the singleton via CrosLibrary::Get(). |
1750 static NetworkLibrary* GetImpl(bool stub); | 1750 static NetworkLibrary* GetImpl(bool stub); |
1751 }; | 1751 }; |
1752 | 1752 |
1753 } // namespace chromeos | 1753 } // namespace chromeos |
1754 | 1754 |
1755 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ | 1755 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ |
OLD | NEW |