Vectorize website settings icons in omnibox
[chromium-blink-merge.git] / components / copresence / tokens.h
blob8895df9710b17afead6b1ea83c2b0e53e45d4213
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
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_COPRESENCE_TOKENS_H_
6 #define COMPONENTS_COPRESENCE_TOKENS_H_
8 #include <string>
10 #include "base/time/time.h"
11 #include "components/copresence/proto/enums.pb.h"
13 namespace copresence {
15 // It's an error to define these constructors inline,
16 // so they're defined in tokens.cc.
18 struct TransmittedToken final {
19 TransmittedToken();
21 std::string id;
22 TokenMedium medium;
23 base::Time start_time;
24 base::Time stop_time;
25 bool broadcast_confirmed;
28 struct ReceivedToken final {
29 enum Validity {
30 UNKNOWN = 0,
31 VALID = 1,
32 INVALID = 2
35 ReceivedToken();
36 ReceivedToken(const std::string& id,
37 TokenMedium medium,
38 base::Time last_time);
40 std::string id;
41 TokenMedium medium;
42 base::Time start_time;
43 base::Time last_time;
44 Validity valid;
47 } // namespace copresence
49 #endif // COMPONENTS_COPRESENCE_TOKENS_H_