| OLD | NEW |
| (Empty) |
| 1 // 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 CHROME_RENDERER_LEAK_DETECTOR_LEAK_DETECTOR_REMOTE_CLIENT_H_ | |
| 6 #define CHROME_RENDERER_LEAK_DETECTOR_LEAK_DETECTOR_REMOTE_CLIENT_H_ | |
| 7 | |
| 8 #include "base/macros.h" | |
| 9 #include "components/metrics/leak_detector/leak_detector.h" | |
| 10 #include "components/metrics/leak_detector/leak_detector.mojom.h" | |
| 11 | |
| 12 class LeakDetectorRemoteClient : public metrics::LeakDetector::Observer { | |
| 13 public: | |
| 14 LeakDetectorRemoteClient(); | |
| 15 ~LeakDetectorRemoteClient() override; | |
| 16 | |
| 17 // metrics::LeakDetector::Observer: | |
| 18 void OnLeaksFound( | |
| 19 const std::vector<metrics::MemoryLeakReportProto>& reports) override; | |
| 20 | |
| 21 private: | |
| 22 // Callback for remote function LeakDetectorRemote::GetParams(). | |
| 23 void OnParamsReceived( | |
| 24 mojo::StructPtr<metrics::mojom::LeakDetectorParams> result); | |
| 25 | |
| 26 // Handle to the remote Mojo interface. | |
| 27 metrics::mojom::LeakDetectorPtr remote_service_; | |
| 28 | |
| 29 DISALLOW_COPY_AND_ASSIGN(LeakDetectorRemoteClient); | |
| 30 }; | |
| 31 | |
| 32 #endif // CHROME_RENDERER_LEAK_DETECTOR_LEAK_DETECTOR_REMOTE_CLIENT_H_ | |
| OLD | NEW |