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

Side by Side Diff: components/cryptauth/data_with_timestamp.h

Issue 2847233003: [EasyUnlock] Move DataWithTimestamp out of ForegroundEidGenerator so it can be shared. (Closed)
Patch Set: fixes Created 3 years, 7 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
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_CRYPTAUTH_BLE_DATA_WITH_TIMESTAMP_H_
6 #define COMPONENTS_CRYPTAUTH_BLE_DATA_WITH_TIMESTAMP_H_
7
8 #include <string>
9
10 namespace cryptauth {
11
12 // Stores EID-related data and timestamps at which time this data becomes
13 // active or inactive.
14 struct DataWithTimestamp {
15 DataWithTimestamp(const std::string& data,
16 const int64_t start_timestamp_ms,
17 const int64_t end_timestamp_ms);
18 DataWithTimestamp(const DataWithTimestamp& other);
19
20 bool ContainsTime(const int64_t timestamp_ms) const;
21 std::string DataInHex() const;
22
23 bool operator==(const DataWithTimestamp& other) const;
24
25 const std::string data;
26 const int64_t start_timestamp_ms;
Kyle Horimoto 2017/04/30 03:17:44 nit: Can you add a comment saying that start is in
Tim Song 2017/05/01 22:23:38 Done.
27 const int64_t end_timestamp_ms;
28 };
29
30 } // namespace
31
32 #endif // COMPONENTS_CRYPTAUTH_BLE_DATA_WITH_TIMESTAMP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698