Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2017 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 REMOTING_PROTOCOL_PROCESS_STATS_ADAPTER_H_ | |
| 6 #define REMOTING_PROTOCOL_PROCESS_STATS_ADAPTER_H_ | |
| 7 | |
| 8 #include "remoting/protocol/process_stats_stub.h" | |
| 9 | |
| 10 namespace remoting { | |
| 11 namespace protocol { | |
| 12 | |
| 13 class AggregatedProcessResourceUsage; | |
| 14 class ClientStub; | |
| 15 | |
| 16 // ProcessStatsAdapter implements ProcessStatsStub and sends data through | |
| 17 // ClientStub. | |
| 18 class ProcessStatsAdapter : public ProcessStatsStub { | |
| 19 public: | |
| 20 // Users should ensure |client_stub| outlives this instance. | |
| 21 explicit ProcessStatsAdapter(ClientStub* client_stub); | |
| 22 ~ProcessStatsAdapter() override; | |
| 23 | |
| 24 // ProcessStatsStub implementation. | |
| 25 void OnProcessStats(const AggregatedProcessResourceUsage& usage) override; | |
| 26 private: | |
|
Sergey Ulanov
2017/05/26 19:27:30
nit: add empty line here
Hzj_jie
2017/05/26 20:42:16
Done.
| |
| 27 ClientStub* const client_stub_; | |
| 28 }; | |
| 29 | |
| 30 } // namespace protocol | |
| 31 } // namespace remoting | |
| 32 | |
| 33 #endif // REMOTING_PROTOCOL_PROCESS_STATS_ADAPTER_H_ | |
| OLD | NEW |