diff options
Diffstat (limited to 'sync/engine')
27 files changed, 80 insertions, 45 deletions
diff --git a/sync/engine/apply_updates_command.cc b/sync/engine/apply_updates_command.cc index 79fd039..35490c3 100644 --- a/sync/engine/apply_updates_command.cc +++ b/sync/engine/apply_updates_command.cc @@ -7,7 +7,9 @@ #include "base/location.h" #include "sync/engine/update_applicator.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/read_transaction.h" +#include "sync/syncable/write_transaction.h" namespace browser_sync { diff --git a/sync/engine/apply_updates_command_unittest.cc b/sync/engine/apply_updates_command_unittest.cc index 6ff6dae..e60c15f 100644 --- a/sync/engine/apply_updates_command_unittest.cc +++ b/sync/engine/apply_updates_command_unittest.cc @@ -14,8 +14,10 @@ #include "sync/protocol/bookmark_specifics.pb.h" #include "sync/protocol/password_specifics.pb.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/read_transaction.h" #include "sync/syncable/syncable_id.h" +#include "sync/syncable/write_transaction.h" #include "sync/test/engine/fake_model_worker.h" #include "sync/test/engine/syncer_command_test.h" #include "sync/test/engine/test_id_factory.h" @@ -27,7 +29,6 @@ namespace browser_sync { using sessions::SyncSession; using std::string; -using syncable::Entry; using syncable::Id; using syncable::MutableEntry; using syncable::ReadTransaction; diff --git a/sync/engine/build_commit_command.cc b/sync/engine/build_commit_command.cc index 974cd37..665613a 100644 --- a/sync/engine/build_commit_command.cc +++ b/sync/engine/build_commit_command.cc @@ -14,8 +14,10 @@ #include "sync/protocol/bookmark_specifics.pb.h" #include "sync/sessions/ordered_commit_set.h" #include "sync/sessions/sync_session.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/mutable_entry.h" #include "sync/syncable/syncable_changes_version.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/time.h" using std::set; diff --git a/sync/engine/build_commit_command.h b/sync/engine/build_commit_command.h index 91eb3203..bdcefe1 100644 --- a/sync/engine/build_commit_command.h +++ b/sync/engine/build_commit_command.h @@ -8,9 +8,14 @@ #include "base/basictypes.h" #include "base/compiler_specific.h" +#include "base/gtest_prod_util.h" #include "sync/engine/syncer_command.h" #include "sync/engine/syncproto.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry_kernel.h" + +namespace syncable { +class Entry; +} namespace browser_sync { diff --git a/sync/engine/cleanup_disabled_types_command.cc b/sync/engine/cleanup_disabled_types_command.cc index 4a774b7..1a94663 100644 --- a/sync/engine/cleanup_disabled_types_command.cc +++ b/sync/engine/cleanup_disabled_types_command.cc @@ -9,7 +9,7 @@ #include "sync/internal_api/public/syncable/model_type.h" #include "sync/sessions/sync_session.h" #include "sync/sessions/sync_session_context.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" namespace browser_sync { diff --git a/sync/engine/commit.cc b/sync/engine/commit.cc index 2f39c23..abef162 100644 --- a/sync/engine/commit.cc +++ b/sync/engine/commit.cc @@ -10,6 +10,8 @@ #include "sync/engine/process_commit_response_command.h" #include "sync/engine/syncer_proto_util.h" #include "sync/sessions/sync_session.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/write_transaction.h" using syncable::SYNCER; using syncable::WriteTransaction; diff --git a/sync/engine/conflict_resolver.cc b/sync/engine/conflict_resolver.cc index 3422f18..d775c1d 100644 --- a/sync/engine/conflict_resolver.cc +++ b/sync/engine/conflict_resolver.cc @@ -15,7 +15,9 @@ #include "sync/engine/syncer_util.h" #include "sync/protocol/nigori_specifics.pb.h" #include "sync/sessions/status_controller.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/cryptographer.h" using std::list; diff --git a/sync/engine/download_updates_command.cc b/sync/engine/download_updates_command.cc index ef41a76..cc8cf4e 100644 --- a/sync/engine/download_updates_command.cc +++ b/sync/engine/download_updates_command.cc @@ -11,7 +11,7 @@ #include "sync/engine/syncer_proto_util.h" #include "sync/engine/syncproto.h" #include "sync/internal_api/public/syncable/model_type_payload_map.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" using sync_pb::DebugInfo; diff --git a/sync/engine/get_commit_ids_command.cc b/sync/engine/get_commit_ids_command.cc index e8653b2..6936cc7 100644 --- a/sync/engine/get_commit_ids_command.cc +++ b/sync/engine/get_commit_ids_command.cc @@ -11,7 +11,9 @@ #include "sync/engine/nigori_util.h" #include "sync/engine/syncer_util.h" #include "sync/engine/throttled_data_type_tracker.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/cryptographer.h" using std::set; diff --git a/sync/engine/get_commit_ids_command.h b/sync/engine/get_commit_ids_command.h index 9aca7cd..3e18f60 100644 --- a/sync/engine/get_commit_ids_command.h +++ b/sync/engine/get_commit_ids_command.h @@ -14,6 +14,7 @@ #include "sync/engine/syncer_util.h" #include "sync/sessions/ordered_commit_set.h" #include "sync/sessions/sync_session.h" +#include "sync/syncable/directory.h" using std::pair; using std::vector; diff --git a/sync/engine/net/server_connection_manager.cc b/sync/engine/net/server_connection_manager.cc index c9a675f..5ffd6a7 100644 --- a/sync/engine/net/server_connection_manager.cc +++ b/sync/engine/net/server_connection_manager.cc @@ -18,7 +18,7 @@ #include "sync/engine/syncer.h" #include "sync/engine/syncproto.h" #include "sync/protocol/sync.pb.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" namespace browser_sync { diff --git a/sync/engine/nigori_util.cc b/sync/engine/nigori_util.cc index 78bb33c..0b34a02 100644 --- a/sync/engine/nigori_util.cc +++ b/sync/engine/nigori_util.cc @@ -10,7 +10,10 @@ #include "base/json/json_writer.h" #include "sync/engine/syncer_util.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/cryptographer.h" namespace syncable { diff --git a/sync/engine/process_commit_response_command.cc b/sync/engine/process_commit_response_command.cc index dfecd39..fbfe941 100644 --- a/sync/engine/process_commit_response_command.cc +++ b/sync/engine/process_commit_response_command.cc @@ -15,7 +15,11 @@ #include "sync/engine/syncer_util.h" #include "sync/engine/syncproto.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/read_transaction.h" +#include "sync/syncable/syncable_util.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/time.h" using syncable::WriteTransaction; diff --git a/sync/engine/process_commit_response_command_unittest.cc b/sync/engine/process_commit_response_command_unittest.cc index 195d58a..bd1b661 100644 --- a/sync/engine/process_commit_response_command_unittest.cc +++ b/sync/engine/process_commit_response_command_unittest.cc @@ -2,19 +2,23 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +#include "sync/engine/process_commit_response_command.h" + #include <vector> #include "base/location.h" #include "base/stringprintf.h" -#include "sync/engine/process_commit_response_command.h" +#include "sync/protocol/bookmark_specifics.pb.h" +#include "sync/protocol/sync.pb.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/read_transaction.h" #include "sync/syncable/syncable_id.h" +#include "sync/syncable/write_transaction.h" #include "sync/test/engine/fake_model_worker.h" #include "sync/test/engine/syncer_command_test.h" #include "sync/test/engine/test_id_factory.h" -#include "sync/protocol/bookmark_specifics.pb.h" -#include "sync/protocol/sync.pb.h" #include "testing/gtest/include/gtest/gtest.h" namespace browser_sync { diff --git a/sync/engine/process_updates_command.cc b/sync/engine/process_updates_command.cc index 59c1d77..a7073a5 100644 --- a/sync/engine/process_updates_command.cc +++ b/sync/engine/process_updates_command.cc @@ -13,7 +13,10 @@ #include "sync/engine/syncer_util.h" #include "sync/engine/syncproto.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/syncable_util.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/cryptographer.h" using std::vector; diff --git a/sync/engine/resolve_conflicts_command.cc b/sync/engine/resolve_conflicts_command.cc index 457e4b7..bac365f 100644 --- a/sync/engine/resolve_conflicts_command.cc +++ b/sync/engine/resolve_conflicts_command.cc @@ -7,7 +7,8 @@ #include "sync/engine/conflict_resolver.h" #include "sync/sessions/session_state.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/write_transaction.h" namespace browser_sync { diff --git a/sync/engine/store_timestamps_command.cc b/sync/engine/store_timestamps_command.cc index e942328..6791ad2 100644 --- a/sync/engine/store_timestamps_command.cc +++ b/sync/engine/store_timestamps_command.cc @@ -7,7 +7,7 @@ #include "sync/internal_api/public/syncable/model_type.h" #include "sync/sessions/status_controller.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" namespace browser_sync { diff --git a/sync/engine/syncer.cc b/sync/engine/syncer.cc index 01c8ae6..da4e27b 100644 --- a/sync/engine/syncer.cc +++ b/sync/engine/syncer.cc @@ -25,13 +25,12 @@ #include "sync/engine/syncproto.h" #include "sync/engine/throttled_data_type_tracker.h" #include "sync/engine/verify_updates_command.h" +#include "sync/syncable/mutable_entry.h" #include "sync/syncable/syncable-inl.h" -#include "sync/syncable/syncable.h" using base::Time; using base::TimeDelta; using sync_pb::ClientCommand; -using syncable::Blob; using syncable::IS_UNAPPLIED_UPDATE; using syncable::SERVER_CTIME; using syncable::SERVER_IS_DEL; @@ -42,8 +41,6 @@ using syncable::SERVER_PARENT_ID; using syncable::SERVER_POSITION_IN_PARENT; using syncable::SERVER_SPECIFICS; using syncable::SERVER_VERSION; -using syncable::SYNCER; -using syncable::WriteTransaction; namespace browser_sync { diff --git a/sync/engine/syncer_proto_util.cc b/sync/engine/syncer_proto_util.cc index 294f0ef..116556f 100644 --- a/sync/engine/syncer_proto_util.cc +++ b/sync/engine/syncer_proto_util.cc @@ -16,8 +16,9 @@ #include "sync/protocol/sync_enums.pb.h" #include "sync/protocol/sync_protocol_error.h" #include "sync/sessions/sync_session.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/entry.h" #include "sync/syncable/syncable-inl.h" -#include "sync/syncable/syncable.h" #include "sync/util/time.h" using browser_sync::SyncProtocolErrorType; diff --git a/sync/engine/syncer_proto_util_unittest.cc b/sync/engine/syncer_proto_util_unittest.cc index fe9f0dc..7f81221 100644 --- a/sync/engine/syncer_proto_util_unittest.cc +++ b/sync/engine/syncer_proto_util_unittest.cc @@ -20,10 +20,9 @@ #include "sync/sessions/session_state.h" #include "sync/sessions/sync_session_context.h" #include "sync/syncable/blob.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" #include "sync/test/engine/mock_connection_manager.h" #include "sync/test/engine/test_directory_setter_upper.h" - #include "testing/gtest/include/gtest/gtest.h" using syncable::Blob; diff --git a/sync/engine/syncer_unittest.cc b/sync/engine/syncer_unittest.cc index cce69aa..81dfec5 100644 --- a/sync/engine/syncer_unittest.cc +++ b/sync/engine/syncer_unittest.cc @@ -41,7 +41,9 @@ #include "sync/protocol/preference_specifics.pb.h" #include "sync/protocol/sync.pb.h" #include "sync/sessions/sync_session_context.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/read_transaction.h" +#include "sync/syncable/write_transaction.h" #include "sync/test/engine/fake_model_worker.h" #include "sync/test/engine/mock_connection_manager.h" #include "sync/test/engine/test_directory_setter_upper.h" @@ -77,7 +79,6 @@ using syncable::WriteTransaction; using syncable::BASE_VERSION; using syncable::CREATE; -using syncable::CREATE_NEW_UPDATE_ITEM; using syncable::GET_BY_HANDLE; using syncable::GET_BY_ID; using syncable::GET_BY_CLIENT_TAG; @@ -95,7 +96,6 @@ using syncable::PARENT_ID; using syncable::PREV_ID; using syncable::BASE_SERVER_SPECIFICS; using syncable::SERVER_IS_DEL; -using syncable::SERVER_NON_UNIQUE_NAME; using syncable::SERVER_PARENT_ID; using syncable::SERVER_POSITION_IN_PARENT; using syncable::SERVER_SPECIFICS; diff --git a/sync/engine/syncer_util.cc b/sync/engine/syncer_util.cc index 4f184bd..0f734cd 100644 --- a/sync/engine/syncer_util.cc +++ b/sync/engine/syncer_util.cc @@ -21,20 +21,22 @@ #include "sync/protocol/nigori_specifics.pb.h" #include "sync/protocol/password_specifics.pb.h" #include "sync/protocol/sync.pb.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/directory.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/read_transaction.h" #include "sync/syncable/syncable_changes_version.h" +#include "sync/syncable/syncable_util.h" +#include "sync/syncable/write_transaction.h" #include "sync/util/cryptographer.h" #include "sync/util/time.h" using syncable::BASE_VERSION; -using syncable::Blob; using syncable::CHANGES_VERSION; -using syncable::CREATE; using syncable::CREATE_NEW_UPDATE_ITEM; using syncable::CTIME; using syncable::Directory; using syncable::Entry; -using syncable::GetModelTypeFromSpecifics; using syncable::GET_BY_HANDLE; using syncable::GET_BY_ID; using syncable::ID; @@ -43,11 +45,9 @@ using syncable::IS_DIR; using syncable::IS_UNAPPLIED_UPDATE; using syncable::IS_UNSYNCED; using syncable::Id; -using syncable::IsRealDataType; using syncable::META_HANDLE; using syncable::MTIME; using syncable::MutableEntry; -using syncable::NEXT_ID; using syncable::NON_UNIQUE_NAME; using syncable::BASE_SERVER_SPECIFICS; using syncable::PARENT_ID; diff --git a/sync/engine/syncer_util.h b/sync/engine/syncer_util.h index 39c03bf..546ac3ff 100644 --- a/sync/engine/syncer_util.h +++ b/sync/engine/syncer_util.h @@ -15,7 +15,8 @@ #include "sync/engine/syncer.h" #include "sync/engine/syncer_types.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry_kernel.h" +#include "sync/syncable/metahandle_set.h" #include "sync/syncable/syncable_id.h" namespace browser_sync { diff --git a/sync/engine/update_applicator.cc b/sync/engine/update_applicator.cc index 5f510f3..921cfb5 100644 --- a/sync/engine/update_applicator.cc +++ b/sync/engine/update_applicator.cc @@ -9,8 +9,10 @@ #include "base/logging.h" #include "sync/engine/syncer_util.h" #include "sync/sessions/session_state.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" #include "sync/syncable/syncable_id.h" +#include "sync/syncable/write_transaction.h" using std::vector; diff --git a/sync/engine/update_applicator.h b/sync/engine/update_applicator.h index 0e28180..cbd2b5e 100644 --- a/sync/engine/update_applicator.h +++ b/sync/engine/update_applicator.h @@ -17,7 +17,12 @@ #include "base/basictypes.h" #include "base/port.h" #include "sync/internal_api/public/engine/model_safe_worker.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/syncable_id.h" + +namespace syncable { +class WriteTransaction; +class Entry; +} namespace browser_sync { diff --git a/sync/engine/verify_updates_command.cc b/sync/engine/verify_updates_command.cc index 0ba0d16..40c75cf 100644 --- a/sync/engine/verify_updates_command.cc +++ b/sync/engine/verify_updates_command.cc @@ -14,15 +14,16 @@ #include "sync/engine/syncproto.h" #include "sync/internal_api/public/engine/model_safe_worker.h" #include "sync/protocol/bookmark_specifics.pb.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/entry.h" +#include "sync/syncable/mutable_entry.h" +#include "sync/syncable/write_transaction.h" namespace browser_sync { -using syncable::WriteTransaction; - using syncable::GET_BY_ID; using syncable::ModelTypeSet; using syncable::SYNCER; +using syncable::WriteTransaction; namespace { diff --git a/sync/engine/verify_updates_command_unittest.cc b/sync/engine/verify_updates_command_unittest.cc index 5f7356e..15324f4 100644 --- a/sync/engine/verify_updates_command_unittest.cc +++ b/sync/engine/verify_updates_command_unittest.cc @@ -7,7 +7,7 @@ #include "sync/protocol/bookmark_specifics.pb.h" #include "sync/sessions/session_state.h" #include "sync/sessions/sync_session.h" -#include "sync/syncable/syncable.h" +#include "sync/syncable/mutable_entry.h" #include "sync/syncable/syncable_id.h" #include "sync/test/engine/fake_model_worker.h" #include "sync/test/engine/syncer_command_test.h" @@ -15,13 +15,10 @@ namespace browser_sync { -using sessions::SyncSession; using sessions::StatusController; using std::string; -using syncable::Entry; using syncable::Id; using syncable::MutableEntry; -using syncable::ReadTransaction; using syncable::UNITTEST; using syncable::WriteTransaction; |