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

Side by Side Diff: sync/test/engine/fake_traffic_recorder.cc

Issue 12088080: [Sync] Add timestamp to TrafficRecorder records (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012 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 #include "sync/test/engine/fake_traffic_recorder.h"
6 #include "sync/util/time.h"
7
8 namespace syncer {
9
10 FakeTrafficRecorder::FakeTrafficRecorder(
11 unsigned int max_messages,
12 unsigned int max_message_size)
13 : TrafficRecorder::TrafficRecorder(max_messages, max_message_size) {
14 SetTime(0);
15 }
16
17 FakeTrafficRecorder::~FakeTrafficRecorder() {
18 }
19
20 base::Time FakeTrafficRecorder::GetTime() {
21 return time_;
22 }
23
24 void FakeTrafficRecorder::SetTime(int64 time) {
25 time_ = ProtoTimeToTime(time);
26 }
27
28 void FakeTrafficRecorder::SetTime(base::Time time) {
29 time_ = time;
30 }
31
32 } // namespace syncer
OLDNEW
« sync/test/engine/fake_traffic_recorder.h ('K') | « sync/test/engine/fake_traffic_recorder.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698