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

Side by Side Diff: sync/test/engine/mock_connection_manager.h

Issue 642023004: Standardize usage of virtual/override/final in sync/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
OLDNEW
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 // Mock ServerConnectionManager class for use in client unit tests. 5 // Mock ServerConnectionManager class for use in client unit tests.
6 6
7 #ifndef SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ 7 #ifndef SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_
8 #define SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ 8 #define SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_
9 9
10 #include <bitset> 10 #include <bitset>
(...skipping 17 matching lines...) Expand all
28 class MidCommitObserver { 28 class MidCommitObserver {
29 public: 29 public:
30 virtual void Observe() = 0; 30 virtual void Observe() = 0;
31 31
32 protected: 32 protected:
33 virtual ~MidCommitObserver() {} 33 virtual ~MidCommitObserver() {}
34 }; 34 };
35 35
36 MockConnectionManager(syncable::Directory*, 36 MockConnectionManager(syncable::Directory*,
37 CancelationSignal* signal); 37 CancelationSignal* signal);
38 virtual ~MockConnectionManager(); 38 ~MockConnectionManager() override;
39 39
40 // Overridden ServerConnectionManager functions. 40 // Overridden ServerConnectionManager functions.
41 virtual bool PostBufferToPath( 41 bool PostBufferToPath(PostBufferParams*,
42 PostBufferParams*, 42 const std::string& path,
43 const std::string& path, 43 const std::string& auth_token,
44 const std::string& auth_token, 44 ScopedServerStatusWatcher* watcher) override;
45 ScopedServerStatusWatcher* watcher) override;
46 45
47 // Control of commit response. 46 // Control of commit response.
48 // NOTE: Commit callback is invoked only once then reset. 47 // NOTE: Commit callback is invoked only once then reset.
49 void SetMidCommitCallback(const base::Closure& callback); 48 void SetMidCommitCallback(const base::Closure& callback);
50 void SetMidCommitObserver(MidCommitObserver* observer); 49 void SetMidCommitObserver(MidCommitObserver* observer);
51 50
52 // Set this if you want commit to perform commit time rename. Will request 51 // Set this if you want commit to perform commit time rename. Will request
53 // that the client renames all commited entries, prepending this string. 52 // that the client renames all commited entries, prepending this string.
54 void SetCommitTimeRename(std::string prepend); 53 void SetCommitTimeRename(std::string prepend);
55 54
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 std::string next_token_; 396 std::string next_token_;
398 397
399 std::vector<sync_pb::ClientToServerMessage> requests_; 398 std::vector<sync_pb::ClientToServerMessage> requests_;
400 399
401 DISALLOW_COPY_AND_ASSIGN(MockConnectionManager); 400 DISALLOW_COPY_AND_ASSIGN(MockConnectionManager);
402 }; 401 };
403 402
404 } // namespace syncer 403 } // namespace syncer
405 404
406 #endif // SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ 405 #endif // SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_
OLDNEW
« no previous file with comments | « sync/test/engine/injectable_sync_context_proxy.h ('k') | sync/test/engine/mock_model_type_sync_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698