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 #include "components/sync_driver/invalidation_adapter.h" | 5 #include "components/sync/driver/invalidation_adapter.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 namespace browser_sync { | 9 namespace browser_sync { |
10 | 10 |
11 InvalidationAdapter::InvalidationAdapter( | 11 InvalidationAdapter::InvalidationAdapter( |
12 const syncer::Invalidation& invalidation) | 12 const syncer::Invalidation& invalidation) |
13 : invalidation_(invalidation) { | 13 : invalidation_(invalidation) {} |
14 } | |
15 | 14 |
16 InvalidationAdapter::~InvalidationAdapter() { | 15 InvalidationAdapter::~InvalidationAdapter() {} |
17 } | |
18 | 16 |
19 bool InvalidationAdapter::IsUnknownVersion() const { | 17 bool InvalidationAdapter::IsUnknownVersion() const { |
20 return invalidation_.is_unknown_version(); | 18 return invalidation_.is_unknown_version(); |
21 } | 19 } |
22 | 20 |
23 const std::string& InvalidationAdapter::GetPayload() const { | 21 const std::string& InvalidationAdapter::GetPayload() const { |
24 return invalidation_.payload(); | 22 return invalidation_.payload(); |
25 } | 23 } |
26 | 24 |
27 int64_t InvalidationAdapter::GetVersion() const { | 25 int64_t InvalidationAdapter::GetVersion() const { |
28 return invalidation_.version(); | 26 return invalidation_.version(); |
29 } | 27 } |
30 | 28 |
31 void InvalidationAdapter::Acknowledge() { | 29 void InvalidationAdapter::Acknowledge() { |
32 invalidation_.Acknowledge(); | 30 invalidation_.Acknowledge(); |
33 } | 31 } |
34 | 32 |
35 void InvalidationAdapter::Drop() { | 33 void InvalidationAdapter::Drop() { |
36 invalidation_.Drop(); | 34 invalidation_.Drop(); |
37 } | 35 } |
38 | 36 |
39 } // namespace browser_sync | 37 } // namespace browser_sync |
OLD | NEW |