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

Side by Side Diff: chrome/browser/sync/sessions/session_state.h

Issue 8189003: Send important client side event information to the server. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: committing. Created 9 years, 2 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 // The 'sessions' namespace comprises all the pieces of state that are 5 // The 'sessions' namespace comprises all the pieces of state that are
6 // combined to form a SyncSession instance. In that way, it can be thought of 6 // combined to form a SyncSession instance. In that way, it can be thought of
7 // as an extension of the SyncSession type itself. Session scoping gives 7 // as an extension of the SyncSession type itself. Session scoping gives
8 // context to things like "conflict progress", "update progress", etc, and the 8 // context to things like "conflict progress", "update progress", etc, and the
9 // separation this file provides allows clients to only include the parts they 9 // separation this file provides allows clients to only include the parts they
10 // need rather than the entire session stack. 10 // need rather than the entire session stack.
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 std::vector<VerifiedUpdate> verified_updates_; 264 std::vector<VerifiedUpdate> verified_updates_;
265 265
266 // Stores the result of the various ApplyUpdate attempts we've made. 266 // Stores the result of the various ApplyUpdate attempts we've made.
267 // May contain duplicate entries. 267 // May contain duplicate entries.
268 std::vector<AppliedUpdate> applied_updates_; 268 std::vector<AppliedUpdate> applied_updates_;
269 }; 269 };
270 270
271 struct SyncCycleControlParameters { 271 struct SyncCycleControlParameters {
272 SyncCycleControlParameters() : conflict_sets_built(false), 272 SyncCycleControlParameters() : conflict_sets_built(false),
273 conflicts_resolved(false), 273 conflicts_resolved(false),
274 items_committed(false) {} 274 items_committed(false),
275 debug_info_sent(false) {}
275 // Set to true by BuildAndProcessConflictSetsCommand if the RESOLVE_CONFLICTS 276 // Set to true by BuildAndProcessConflictSetsCommand if the RESOLVE_CONFLICTS
276 // step is needed. 277 // step is needed.
277 bool conflict_sets_built; 278 bool conflict_sets_built;
278 279
279 // Set to true by ResolveConflictsCommand if any forward progress was made. 280 // Set to true by ResolveConflictsCommand if any forward progress was made.
280 bool conflicts_resolved; 281 bool conflicts_resolved;
281 282
282 // Set to true by PostCommitMessageCommand if any commits were successful. 283 // Set to true by PostCommitMessageCommand if any commits were successful.
283 bool items_committed; 284 bool items_committed;
285
286 // True indicates debug info has been sent once this session.
287 bool debug_info_sent;
284 }; 288 };
285 289
286 // DirtyOnWrite wraps a value such that any write operation will update a 290 // DirtyOnWrite wraps a value such that any write operation will update a
287 // specified dirty bit, which can be used to determine if a notification should 291 // specified dirty bit, which can be used to determine if a notification should
288 // be sent due to state change. 292 // be sent due to state change.
289 template <typename T> 293 template <typename T>
290 class DirtyOnWrite { 294 class DirtyOnWrite {
291 public: 295 public:
292 explicit DirtyOnWrite(bool* dirty) : dirty_(dirty) {} 296 explicit DirtyOnWrite(bool* dirty) : dirty_(dirty) {}
293 DirtyOnWrite(bool* dirty, const T& t) : t_(t), dirty_(dirty) {} 297 DirtyOnWrite(bool* dirty, const T& t) : t_(t), dirty_(dirty) {}
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 ~PerModelSafeGroupState(); 341 ~PerModelSafeGroupState();
338 342
339 UpdateProgress update_progress; 343 UpdateProgress update_progress;
340 ConflictProgress conflict_progress; 344 ConflictProgress conflict_progress;
341 }; 345 };
342 346
343 } // namespace sessions 347 } // namespace sessions
344 } // namespace browser_sync 348 } // namespace browser_sync
345 349
346 #endif // CHROME_BROWSER_SYNC_SESSIONS_SESSION_STATE_H_ 350 #endif // CHROME_BROWSER_SYNC_SESSIONS_SESSION_STATE_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/protocol/sync_proto.gyp ('k') | chrome/browser/sync/sessions/status_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698