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

Side by Side Diff: Source/wtf/CurrentTime.h

Issue 1130423002: Add a unit test for timers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Review comments. Created 5 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 | Annotate | Revision Log
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved.
3 * Copyright (C) 2008 Google Inc. All rights reserved. 3 * Copyright (C) 2008 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // Provides a monotonically increasing time in seconds since an arbitrary point in the past. 50 // Provides a monotonically increasing time in seconds since an arbitrary point in the past.
51 // On unsupported platforms, this function only guarantees the result will be no n-decreasing. 51 // On unsupported platforms, this function only guarantees the result will be no n-decreasing.
52 WTF_EXPORT double monotonicallyIncreasingTime(); 52 WTF_EXPORT double monotonicallyIncreasingTime();
53 53
54 // Provides a timestamp that aligns with system tracing utilities on the host op erating 54 // Provides a timestamp that aligns with system tracing utilities on the host op erating
55 // system. 55 // system.
56 WTF_EXPORT double systemTraceTime(); 56 WTF_EXPORT double systemTraceTime();
57 57
58 typedef double(*TimeFunction)(void); 58 typedef double(*TimeFunction)(void);
59 void setCurrentTimeFunction(TimeFunction); 59 void setCurrentTimeFunction(TimeFunction);
60 void setMonotonicallyIncreasingTimeFunction(TimeFunction); 60 WTF_EXPORT void setMonotonicallyIncreasingTimeFunction(TimeFunction);
61 void setSystemTraceTimeFunction(TimeFunction); 61 void setSystemTraceTimeFunction(TimeFunction);
62 62
63 63
64 } // namespace WTF 64 } // namespace WTF
65 65
66 using WTF::currentTime; 66 using WTF::currentTime;
67 using WTF::currentTimeMS; 67 using WTF::currentTimeMS;
68 using WTF::monotonicallyIncreasingTime; 68 using WTF::monotonicallyIncreasingTime;
69 using WTF::systemTraceTime; 69 using WTF::systemTraceTime;
70 70
71 #endif // CurrentTime_h 71 #endif // CurrentTime_h
OLDNEW
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698