blob: e4b637148f02c44e6053c68357950bcae936b954 [file] [log] [blame]
wittmane16da2782016-09-21 16:43:041// Copyright 2016 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#ifndef COMPONENTS_METRICS_CALL_STACK_PROFILE_COLLECTOR_H_
6#define COMPONENTS_METRICS_CALL_STACK_PROFILE_COLLECTOR_H_
7
8#include "base/macros.h"
9#include "components/metrics/public/interfaces/call_stack_profile_collector.mojom.h"
10
11namespace metrics {
12
13class CallStackProfileCollector : public mojom::CallStackProfileCollector {
14 public:
Mike Wittman16fa5362018-09-04 17:27:3015 CallStackProfileCollector();
wittmane16da2782016-09-21 16:43:0416 ~CallStackProfileCollector() override;
17
wittman4472aa92016-09-22 20:13:4618 // Create a collector to receive profiles from |expected_process|.
Mike Wittman16fa5362018-09-04 17:27:3019 static void Create(mojom::CallStackProfileCollectorRequest request);
wittmane16da2782016-09-21 16:43:0420
21 // mojom::CallStackProfileCollector:
Xi Cheng4dec7e42018-08-10 16:54:1122 void Collect(base::TimeTicks start_timestamp,
Mike Wittman16fa5362018-09-04 17:27:3023 mojom::SampledProfilePtr profile) override;
wittmane16da2782016-09-21 16:43:0424
25 private:
wittmane16da2782016-09-21 16:43:0426 DISALLOW_COPY_AND_ASSIGN(CallStackProfileCollector);
27};
28
29} // namespace metrics
30
31#endif // COMPONENTS_METRICS_CALL_STACK_PROFILE_COLLECTOR_H_