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 #include <vector> |
| 6 |
| 7 #include "base/callback.h" |
| 8 #include "remoting/proto/process_stats.pb.h" |
| 9 #include "remoting/protocol/process_stats_stub.h" |
| 10 |
| 11 namespace remoting { |
| 12 namespace protocol { |
| 13 |
| 14 class FakeProcessStatsStub final : public ProcessStatsStub { |
| 15 public: |
| 16 FakeProcessStatsStub(); |
| 17 ~FakeProcessStatsStub() override; |
| 18 |
| 19 // ProcessStatsStub implementation. |
| 20 void OnProcessStats(const AggregatedProcessResourceUsage& usage) override; |
| 21 |
| 22 const std::vector<AggregatedProcessResourceUsage>& received() const; |
| 23 |
| 24 void set_quit_closure(base::Closure quit_closure); |
| 25 void set_expected_usage_count(size_t expected_usage_count); |
| 26 |
| 27 private: |
| 28 std::vector<AggregatedProcessResourceUsage> received_; |
| 29 size_t expected_usage_count_ = 0; |
| 30 base::Closure quit_closure_; |
| 31 }; |
| 32 |
| 33 } // namespace protocol |
| 34 } // namespace remoting |
OLD | NEW |