| OLD | NEW |
| 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 #include "sync/sessions/sync_session.h" | 5 #include "sync/sessions/sync_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <iterator> | 8 #include <iterator> |
| 9 | 9 |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| 11 #include "sync/internal_api/public/syncable/model_type.h" | 11 #include "sync/internal_api/public/syncable/model_type.h" |
| 12 #include "sync/syncable/directory.h" | 12 #include "sync/syncable/directory.h" |
| 13 | 13 |
| 14 namespace csync { | 14 namespace syncer { |
| 15 namespace sessions { | 15 namespace sessions { |
| 16 | 16 |
| 17 namespace { | 17 namespace { |
| 18 | 18 |
| 19 std::set<ModelSafeGroup> ComputeEnabledGroups( | 19 std::set<ModelSafeGroup> ComputeEnabledGroups( |
| 20 const ModelSafeRoutingInfo& routing_info, | 20 const ModelSafeRoutingInfo& routing_info, |
| 21 const std::vector<ModelSafeWorker*>& workers) { | 21 const std::vector<ModelSafeWorker*>& workers) { |
| 22 std::set<ModelSafeGroup> enabled_groups; | 22 std::set<ModelSafeGroup> enabled_groups; |
| 23 // Project the list of enabled types (i.e., types in the routing | 23 // Project the list of enabled types (i.e., types in the routing |
| 24 // info) to a list of enabled groups. | 24 // info) to a list of enabled groups. |
| (...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 // We want to verify that, for all commands attempted, we successfully spoke | 250 // We want to verify that, for all commands attempted, we successfully spoke |
| 251 // with the server. Therefore, we verify no errors and at least one SYNCER_OK. | 251 // with the server. Therefore, we verify no errors and at least one SYNCER_OK. |
| 252 return reached_server && !HadErrors(state); | 252 return reached_server && !HadErrors(state); |
| 253 } | 253 } |
| 254 | 254 |
| 255 void SyncSession::SetFinished() { | 255 void SyncSession::SetFinished() { |
| 256 finished_ = true; | 256 finished_ = true; |
| 257 } | 257 } |
| 258 | 258 |
| 259 } // namespace sessions | 259 } // namespace sessions |
| 260 } // namespace csync | 260 } // namespace syncer |
| OLD | NEW |