| OLD | NEW |
| 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_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ | 5 #ifndef SYNC_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ |
| 6 #define SYNC_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ | 6 #define SYNC_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ |
| 7 | 7 |
| 8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
| 9 #include "sync/internal_api/public/non_blocking_sync_common.h" | 9 #include "sync/internal_api/public/non_blocking_sync_common.h" |
| 10 #include "sync/internal_api/public/sync_context_proxy.h" | 10 #include "sync/internal_api/public/sync_context_proxy.h" |
| 11 | 11 |
| 12 namespace syncer { | 12 namespace syncer { |
| 13 | 13 |
| 14 class ModelTypeSyncProxyImpl; | 14 class ModelTypeSyncProxyImpl; |
| 15 | 15 |
| 16 // A non-functional implementation of SyncContextProxy. | 16 // A non-functional implementation of SyncContextProxy. |
| 17 // | 17 // |
| 18 // It supports Clone(), but not much else. Useful for testing. | 18 // It supports Clone(), but not much else. Useful for testing. |
| 19 class NullSyncContextProxy : public SyncContextProxy { | 19 class NullSyncContextProxy : public SyncContextProxy { |
| 20 public: | 20 public: |
| 21 NullSyncContextProxy(); | 21 NullSyncContextProxy(); |
| 22 virtual ~NullSyncContextProxy(); | 22 virtual ~NullSyncContextProxy(); |
| 23 | 23 |
| 24 virtual void ConnectTypeToSync( | 24 virtual void ConnectTypeToSync( |
| 25 syncer::ModelType type, | 25 syncer::ModelType type, |
| 26 const DataTypeState& data_type_state, | 26 const DataTypeState& data_type_state, |
| 27 const UpdateResponseDataList& saved_pending_updates, | 27 const UpdateResponseDataList& saved_pending_updates, |
| 28 const base::WeakPtr<ModelTypeSyncProxyImpl>& type_sync_proxy) OVERRIDE; | 28 const base::WeakPtr<ModelTypeSyncProxyImpl>& type_sync_proxy) override; |
| 29 virtual void Disconnect(syncer::ModelType type) OVERRIDE; | 29 virtual void Disconnect(syncer::ModelType type) override; |
| 30 virtual scoped_ptr<SyncContextProxy> Clone() const OVERRIDE; | 30 virtual scoped_ptr<SyncContextProxy> Clone() const override; |
| 31 }; | 31 }; |
| 32 | 32 |
| 33 } // namespace syncer | 33 } // namespace syncer |
| 34 | 34 |
| 35 #endif // SYNC_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ | 35 #endif // SYNC_INTERNAL_API_PUBLIC_TEST_NULL_SYNC_CONTEXT_PROXY_H_ |
| OLD | NEW |