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

Side by Side Diff: chromeos/network/shill_property_handler.h

Issue 23684042: Eliminate NetworkManagerChanged (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 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) 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 CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_ 5 #ifndef CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_
6 #define CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_ 6 #define CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_
7 7
8 #include <list> 8 #include <list>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 // Called when a property for a watched device has changed. 68 // Called when a property for a watched device has changed.
69 virtual void UpdateDeviceProperty( 69 virtual void UpdateDeviceProperty(
70 const std::string& device_path, 70 const std::string& device_path,
71 const std::string& key, 71 const std::string& key,
72 const base::Value& value) = 0; 72 const base::Value& value) = 0;
73 73
74 // Called when the list of devices with portal check enabled changes. 74 // Called when the list of devices with portal check enabled changes.
75 virtual void CheckPortalListChanged( 75 virtual void CheckPortalListChanged(
76 const std::string& check_portal_list) = 0; 76 const std::string& check_portal_list) = 0;
77 77
78 // Called when one or more manager properties (e.g. a technology list) 78 // Called when one a technology list changes.
pneubeck (no reviews) 2013/09/11 20:13:35 fix comment
stevenjb 2013/09/11 21:23:46 Done.
79 // changes. 79 virtual void TechnologyListChanged() = 0;
80 virtual void NotifyManagerPropertyChanged() = 0;
81 80
82 // Called when a managed state list has changed, after properties for any 81 // Called when a managed state list has changed, after properties for any
83 // new entries in the list have been received and 82 // new entries in the list have been received and
84 // UpdateManagedStateProperties has been called for each new entry. 83 // UpdateManagedStateProperties has been called for each new entry.
85 virtual void ManagedStateListChanged(ManagedState::ManagedType type) = 0; 84 virtual void ManagedStateListChanged(ManagedState::ManagedType type) = 0;
86 85
87 protected: 86 protected:
88 virtual ~Listener() {} 87 virtual ~Listener() {}
89 }; 88 };
90 89
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 // Callback for dbus method fetching properties. 135 // Callback for dbus method fetching properties.
137 void ManagerPropertiesCallback(DBusMethodCallStatus call_status, 136 void ManagerPropertiesCallback(DBusMethodCallStatus call_status,
138 const base::DictionaryValue& properties); 137 const base::DictionaryValue& properties);
139 138
140 // Notifies the listener when a ManagedStateList has changed and all pending 139 // Notifies the listener when a ManagedStateList has changed and all pending
141 // updates have been received. |key| can either identify the list that 140 // updates have been received. |key| can either identify the list that
142 // has changed or an empty string if multiple lists may have changed. 141 // has changed or an empty string if multiple lists may have changed.
143 void CheckPendingStateListUpdates(const std::string& key); 142 void CheckPendingStateListUpdates(const std::string& key);
144 143
145 // Called form OnPropertyChanged() and ManagerPropertiesCallback(). 144 // Called form OnPropertyChanged() and ManagerPropertiesCallback().
146 // Returns true if observers should be notified. 145 void ManagerPropertyChanged(const std::string& key,
147 bool ManagerPropertyChanged(const std::string& key,
148 const base::Value& value); 146 const base::Value& value);
149 147
150 // Requests properties for new entries in the list for |type| as follows: 148 // Requests properties for new entries in the list for |type| as follows:
151 // * Any new Device objects for MANAGED_TYPE_DEVICE 149 // * Any new Device objects for MANAGED_TYPE_DEVICE
152 // * Any new Service objects for MANAGED_TYPE_NETWORK 150 // * Any new Service objects for MANAGED_TYPE_NETWORK
153 // * Additional new Service objects for MANAGED_TYPE_FAVORITE that were not 151 // * Additional new Service objects for MANAGED_TYPE_FAVORITE that were not
154 // requested for MANAGED_TYPE_NETWORK (i.e. only request objects once). 152 // requested for MANAGED_TYPE_NETWORK (i.e. only request objects once).
155 // For this to avoid duplicate requests, this must be called with 153 // For this to avoid duplicate requests, this must be called with
156 // MANAGED_TYPE_NETWORK before MANAGED_TYPE_FAVORITE. 154 // MANAGED_TYPE_NETWORK before MANAGED_TYPE_FAVORITE.
157 void UpdateProperties(ManagedState::ManagedType type, 155 void UpdateProperties(ManagedState::ManagedType type,
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 std::set<std::string> enabling_technologies_; 226 std::set<std::string> enabling_technologies_;
229 std::set<std::string> uninitialized_technologies_; 227 std::set<std::string> uninitialized_technologies_;
230 228
231 DISALLOW_COPY_AND_ASSIGN(ShillPropertyHandler); 229 DISALLOW_COPY_AND_ASSIGN(ShillPropertyHandler);
232 }; 230 };
233 231
234 } // namespace internal 232 } // namespace internal
235 } // namespace chromeos 233 } // namespace chromeos
236 234
237 #endif // CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_ 235 #endif // CHROMEOS_NETWORK_SHILL_PROPERTY_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698