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

Side by Side Diff: sync/test/fake_server/fake_server.h

Issue 1162943002: Replace more ObserverList with base::ObserverList. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@observer
Patch Set: Created 5 years, 6 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
« no previous file with comments | « sync/sessions/sync_session_context.h ('k') | sync/test/fake_sync_encryption_handler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_ 5 #ifndef SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_
6 #define SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_ 6 #define SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 // |error_type_| or |triggered_actionable_error_|) on every other request. 199 // |error_type_| or |triggered_actionable_error_|) on every other request.
200 // |alternate_triggered_errors_| is set if this feature is enabled and 200 // |alternate_triggered_errors_| is set if this feature is enabled and
201 // |request_counter_| is used to send triggered errors on odd-numbered 201 // |request_counter_| is used to send triggered errors on odd-numbered
202 // requests. Note that |request_counter_| can be reset and is not necessarily 202 // requests. Note that |request_counter_| can be reset and is not necessarily
203 // indicative of the total number of requests handled during the object's 203 // indicative of the total number of requests handled during the object's
204 // lifetime. 204 // lifetime.
205 bool alternate_triggered_errors_; 205 bool alternate_triggered_errors_;
206 int request_counter_; 206 int request_counter_;
207 207
208 // FakeServer's observers. 208 // FakeServer's observers.
209 ObserverList<Observer, true> observers_; 209 base::ObserverList<Observer, true> observers_;
210 210
211 // When true, the server operates normally. When false, a failure is returned 211 // When true, the server operates normally. When false, a failure is returned
212 // on every request. This is used to simulate a network failure on the client. 212 // on every request. This is used to simulate a network failure on the client.
213 bool network_enabled_; 213 bool network_enabled_;
214 }; 214 };
215 215
216 } // namespace fake_server 216 } // namespace fake_server
217 217
218 #endif // SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_ 218 #endif // SYNC_TEST_FAKE_SERVER_FAKE_SERVER_H_
OLDNEW
« no previous file with comments | « sync/sessions/sync_session_context.h ('k') | sync/test/fake_sync_encryption_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698