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

Side by Side Diff: chrome/browser/chromeos/cros/network_library.h

Issue 7753020: Revert recent changes to base::Value (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
OLDNEW
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_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 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 enum TechnologyFamily technology_family() const { return technology_family_; } 406 enum TechnologyFamily technology_family() const { return technology_family_; }
407 const CellularApnList& provider_apn_list() const { 407 const CellularApnList& provider_apn_list() const {
408 return provider_apn_list_; 408 return provider_apn_list_;
409 } 409 }
410 410
411 // Updates the property specified by |key| with the contents of 411 // Updates the property specified by |key| with the contents of
412 // |value|. Returns false on failure. Upon success, returns the 412 // |value|. Returns false on failure. Upon success, returns the
413 // PropertyIndex that was updated in |index|. |index| may be NULL 413 // PropertyIndex that was updated in |index|. |index| may be NULL
414 // if not needed. 414 // if not needed.
415 bool UpdateStatus(const std::string& key, 415 bool UpdateStatus(const std::string& key,
416 Value* value, 416 const Value& value,
417 PropertyIndex *index); 417 PropertyIndex *index);
418 418
419 NativeNetworkDeviceParser* device_parser() { return device_parser_.get(); } 419 NativeNetworkDeviceParser* device_parser() { return device_parser_.get(); }
420 420
421 protected: 421 protected:
422 void set_unique_id(const std::string& unique_id) { unique_id_ = unique_id; } 422 void set_unique_id(const std::string& unique_id) { unique_id_ = unique_id; }
423 423
424 private: 424 private:
425 // This allows NetworkDeviceParser and its subclasses access to 425 // This allows NetworkDeviceParser and its subclasses access to
426 // device privates so that they can be reconstituted during parsing. 426 // device privates so that they can be reconstituted during parsing.
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
628 } 628 }
629 static bool IsDisconnectedState(ConnectionState state) { 629 static bool IsDisconnectedState(ConnectionState state) {
630 return (state == STATE_UNKNOWN || 630 return (state == STATE_UNKNOWN ||
631 state == STATE_IDLE || 631 state == STATE_IDLE ||
632 state == STATE_DISCONNECT || 632 state == STATE_DISCONNECT ||
633 state == STATE_FAILURE || 633 state == STATE_FAILURE ||
634 state == STATE_ACTIVATION_FAILURE); 634 state == STATE_ACTIVATION_FAILURE);
635 } 635 }
636 636
637 virtual bool UpdateStatus(const std::string& key, 637 virtual bool UpdateStatus(const std::string& key,
638 Value* value, 638 const Value& value,
639 PropertyIndex* index); 639 PropertyIndex* index);
640 640
641 protected: 641 protected:
642 Network(const std::string& service_path, 642 Network(const std::string& service_path,
643 ConnectionType type, 643 ConnectionType type,
644 NativeNetworkParser* parser); 644 NativeNetworkParser* parser);
645 645
646 // Set the state and update flags if necessary. 646 // Set the state and update flags if necessary.
647 void SetState(ConnectionState state); 647 void SetState(ConnectionState state);
648 648
(...skipping 978 matching lines...) Expand 10 before | Expand all | Expand 10 after
1627 virtual void SwitchToPreferredNetwork() = 0; 1627 virtual void SwitchToPreferredNetwork() = 0;
1628 1628
1629 // Factory function, creates a new instance and returns ownership. 1629 // Factory function, creates a new instance and returns ownership.
1630 // For normal usage, access the singleton via CrosLibrary::Get(). 1630 // For normal usage, access the singleton via CrosLibrary::Get().
1631 static NetworkLibrary* GetImpl(bool stub); 1631 static NetworkLibrary* GetImpl(bool stub);
1632 }; 1632 };
1633 1633
1634 } // namespace chromeos 1634 } // namespace chromeos
1635 1635
1636 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ 1636 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/cros/native_network_parser.cc ('k') | chrome/browser/chromeos/cros/network_library.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698