blob: da3b61da3bc64d2d8a3648753813a6c7ded7ce58 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef COMPONENTS_FEATURE_ENGAGEMENT_TRACKER_INTERNAL_TIME_PROVIDER_H_
#define COMPONENTS_FEATURE_ENGAGEMENT_TRACKER_INTERNAL_TIME_PROVIDER_H_
#include <stdint.h>
#include "base/macros.h"
namespace feature_engagement_tracker {
// A TimeProvider provides functionality related to time.
class TimeProvider {
public:
virtual ~TimeProvider() = default;
// Returns the number of days since epoch (1970-01-01) in the local timezone.
virtual uint32_t GetCurrentDay() const = 0;
protected:
TimeProvider() = default;
private:
DISALLOW_COPY_AND_ASSIGN(TimeProvider);
};
} // namespace feature_engagement_tracker
#endif // COMPONENTS_FEATURE_ENGAGEMENT_TRACKER_INTERNAL_TIME_PROVIDER_H_
|