Index: chrome/browser/sync/sessions/sync_session.h |
diff --git a/chrome/browser/sync/sessions/sync_session.h b/chrome/browser/sync/sessions/sync_session.h |
index ce7c9e5dd11da04267ce648cf907b058190a2673..7822f4b802ff20de97c26d0d5a3b785e76f7a555 100644 |
--- a/chrome/browser/sync/sessions/sync_session.h |
+++ b/chrome/browser/sync/sessions/sync_session.h |
@@ -35,8 +35,6 @@ namespace browser_sync { |
class ModelSafeWorker; |
namespace sessions { |
-typedef std::pair<sync_pb::GetUpdatesCallerInfo::GetUpdatesSource, |
- syncable::ModelTypeBitSet> SyncSourceInfo; |
class SyncSession { |
public: |
@@ -92,8 +90,19 @@ class SyncSession { |
// engine again. |
bool HasMoreToSync() const; |
- SyncSessionContext* context() { return context_; } |
- Delegate* delegate() { return delegate_; } |
+ // Collects all state pertaining to how and why |s| originated and unions it |
+ // with corresponding state in |this|, leaving |s| unchanged. Allows |this| |
+ // to take on the responsibilities |s| had (e.g. certain data types) in the |
+ // next SyncShare operation using |this|, rather than needed two separate |
+ // sessions. |
+ void Coalesce(const SyncSession* s); |
+ |
+ // Should be called any time |this| is being re-used in a new call to |
+ // SyncShare (e.g., HasMoreToSync returned true). |
+ void ResetTransientState(); |
+ |
+ SyncSessionContext* context() const { return context_; } |
+ Delegate* delegate() const { return delegate_; } |
syncable::WriteTransaction* write_transaction() { return write_transaction_; } |
StatusController* status_controller() { return status_controller_.get(); } |