Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(114)

Side by Side Diff: remoting/protocol/connection_tester.h

Issue 2164163002: Simplify data channel creation logic in WebRTC-based protocol (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « remoting/protocol/channel_dispatcher_base.cc ('k') | remoting/protocol/connection_tester.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef REMOTING_PROTOCOL_CONNECTION_TESTER_H_ 5 #ifndef REMOTING_PROTOCOL_CONNECTION_TESTER_H_
6 #define REMOTING_PROTOCOL_CONNECTION_TESTER_H_ 6 #define REMOTING_PROTOCOL_CONNECTION_TESTER_H_
7 7
8 #include <list> 8 #include <list>
9 #include <memory> 9 #include <memory>
10 #include <vector> 10 #include <vector>
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 MessagePipeConnectionTester(MessagePipe* client_pipe, 114 MessagePipeConnectionTester(MessagePipe* client_pipe,
115 MessagePipe* host_pipe, 115 MessagePipe* host_pipe,
116 int message_size, 116 int message_size,
117 int message_count); 117 int message_count);
118 ~MessagePipeConnectionTester() override; 118 ~MessagePipeConnectionTester() override;
119 119
120 void RunAndCheckResults(); 120 void RunAndCheckResults();
121 121
122 protected: 122 protected:
123 // MessagePipe::EventHandler interface. 123 // MessagePipe::EventHandler interface.
124 void OnMessagePipeOpen() override;
124 void OnMessageReceived(std::unique_ptr<CompoundBuffer> message) override; 125 void OnMessageReceived(std::unique_ptr<CompoundBuffer> message) override;
125 void OnMessagePipeClosed() override; 126 void OnMessagePipeClosed() override;
126 127
127 private: 128 private:
128 base::RunLoop run_loop_; 129 base::RunLoop run_loop_;
129 MessagePipe* host_pipe_; 130 MessagePipe* host_pipe_;
130 MessagePipe* client_pipe_; 131 MessagePipe* client_pipe_;
131 int message_size_; 132 int message_size_;
132 int message_count_; 133 int message_count_;
133 134
134 std::vector<std::unique_ptr<VideoPacket>> sent_messages_; 135 std::vector<std::unique_ptr<VideoPacket>> sent_messages_;
135 std::vector<std::unique_ptr<VideoPacket>> received_messages_; 136 std::vector<std::unique_ptr<VideoPacket>> received_messages_;
136 }; 137 };
137 138
138 } // namespace protocol 139 } // namespace protocol
139 } // namespace remoting 140 } // namespace remoting
140 141
141 #endif // REMOTING_PROTOCOL_CONNECTION_TESTER_H_ 142 #endif // REMOTING_PROTOCOL_CONNECTION_TESTER_H_
OLDNEW
« no previous file with comments | « remoting/protocol/channel_dispatcher_base.cc ('k') | remoting/protocol/connection_tester.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698