1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- #ifndef BASE_METRICS_USER_METRICS_H_
- #define BASE_METRICS_USER_METRICS_H_
- #include <string>
- #include "base/base_export.h"
- #include "base/callback.h"
- #include "base/metrics/user_metrics_action.h"
- #include "base/single_thread_task_runner.h"
- namespace base {
- class TimeTicks;
- BASE_EXPORT void RecordAction(const UserMetricsAction& action);
- BASE_EXPORT void RecordComputedAction(const std::string& action);
- BASE_EXPORT void RecordComputedActionAt(const std::string& action,
- TimeTicks action_time);
- BASE_EXPORT void RecordComputedActionSince(const std::string& action,
- TimeDelta time_since);
- using ActionCallback = RepeatingCallback<void(const std::string&, TimeTicks)>;
- BASE_EXPORT void AddActionCallback(const ActionCallback& callback);
- BASE_EXPORT void RemoveActionCallback(const ActionCallback& callback);
- BASE_EXPORT void SetRecordActionTaskRunner(
- scoped_refptr<SingleThreadTaskRunner> task_runner);
- BASE_EXPORT scoped_refptr<SingleThreadTaskRunner> GetRecordActionTaskRunner();
- }
- #endif
|