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

Side by Side Diff: sync/test/mock_invalidation.h

Issue 629733002: replace OVERRIDE and FINAL with override and 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
« no previous file with comments | « sync/test/local_sync_test_server.h ('k') | sync/test/null_directory_change_delegate.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_TEST_MOCK_INVALIDATION_H_ 5 #ifndef SYNC_TEST_MOCK_INVALIDATION_H_
6 #define SYNC_TEST_MOCK_INVALIDATION_H_ 6 #define SYNC_TEST_MOCK_INVALIDATION_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "sync/internal_api/public/base/invalidation_interface.h" 9 #include "sync/internal_api/public/base/invalidation_interface.h"
10 10
11 namespace syncer { 11 namespace syncer {
12 12
13 // An InvalidationInterface used by sync for testing. 13 // An InvalidationInterface used by sync for testing.
14 // It does not support any form of acknowledgements. 14 // It does not support any form of acknowledgements.
15 class MockInvalidation : public InvalidationInterface { 15 class MockInvalidation : public InvalidationInterface {
16 public: 16 public:
17 // Helpers to build new MockInvalidations. 17 // Helpers to build new MockInvalidations.
18 static scoped_ptr<MockInvalidation> BuildUnknownVersion(); 18 static scoped_ptr<MockInvalidation> BuildUnknownVersion();
19 static scoped_ptr<MockInvalidation> Build(int64 version, 19 static scoped_ptr<MockInvalidation> Build(int64 version,
20 const std::string& payload); 20 const std::string& payload);
21 21
22 virtual ~MockInvalidation(); 22 virtual ~MockInvalidation();
23 23
24 // Implementation of InvalidationInterface. 24 // Implementation of InvalidationInterface.
25 virtual bool IsUnknownVersion() const OVERRIDE; 25 virtual bool IsUnknownVersion() const override;
26 virtual const std::string& GetPayload() const OVERRIDE; 26 virtual const std::string& GetPayload() const override;
27 virtual int64 GetVersion() const OVERRIDE; 27 virtual int64 GetVersion() const override;
28 virtual void Acknowledge() OVERRIDE; 28 virtual void Acknowledge() override;
29 virtual void Drop() OVERRIDE; 29 virtual void Drop() override;
30 30
31 protected: 31 protected:
32 MockInvalidation(bool is_unknown_version, 32 MockInvalidation(bool is_unknown_version,
33 int64 version, 33 int64 version,
34 const std::string& payload); 34 const std::string& payload);
35 35
36 // Whether or not this is an 'unknown version' invalidation. 36 // Whether or not this is an 'unknown version' invalidation.
37 const bool is_unknown_version_; 37 const bool is_unknown_version_;
38 38
39 // The version of this invalidation. Valid only if !is_unknown_version_. 39 // The version of this invalidation. Valid only if !is_unknown_version_.
40 const int64 version_; 40 const int64 version_;
41 41
42 // The payload of this invalidation. Valid only if !is_unknown_version_. 42 // The payload of this invalidation. Valid only if !is_unknown_version_.
43 const std::string payload_; 43 const std::string payload_;
44 }; 44 };
45 45
46 } // namespace syncer 46 } // namespace syncer
47 47
48 #endif // SYNC_TEST_MOCK_INVALIDATION_H_ 48 #endif // SYNC_TEST_MOCK_INVALIDATION_H_
OLDNEW
« no previous file with comments | « sync/test/local_sync_test_server.h ('k') | sync/test/null_directory_change_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698