OLD | NEW |
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 NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ | 5 #ifndef NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ |
6 #define NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ | 6 #define NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/strings/string_piece.h" | 10 #include "base/strings/string_piece.h" |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
175 | 175 |
176 // Construct an expected SPDY CREDENTIAL frame. | 176 // Construct an expected SPDY CREDENTIAL frame. |
177 // |credential| is the credential to send. | 177 // |credential| is the credential to send. |
178 // Returns the constructed frame. The caller takes ownership of the frame. | 178 // Returns the constructed frame. The caller takes ownership of the frame. |
179 SpdyFrame* ConstructSpdyCredential(const SpdyCredential& credential); | 179 SpdyFrame* ConstructSpdyCredential(const SpdyCredential& credential); |
180 | 180 |
181 // Construct a SPDY PING frame. | 181 // Construct a SPDY PING frame. |
182 // Returns the constructed frame. The caller takes ownership of the frame. | 182 // Returns the constructed frame. The caller takes ownership of the frame. |
183 SpdyFrame* ConstructSpdyPing(uint32 ping_id); | 183 SpdyFrame* ConstructSpdyPing(uint32 ping_id); |
184 | 184 |
185 // Construct a SPDY GOAWAY frame. | 185 // Construct a SPDY GOAWAY frame with last_good_stream_id = 0. |
186 // Returns the constructed frame. The caller takes ownership of the frame. | 186 // Returns the constructed frame. The caller takes ownership of the frame. |
187 SpdyFrame* ConstructSpdyGoAway(); | 187 SpdyFrame* ConstructSpdyGoAway(); |
188 | 188 |
| 189 // Construct a SPDY GOAWAY frame with the specified last_good_stream_id. |
| 190 // Returns the constructed frame. The caller takes ownership of the frame. |
| 191 SpdyFrame* ConstructSpdyGoAway(SpdyStreamId last_good_stream_id); |
| 192 |
189 // Construct a SPDY WINDOW_UPDATE frame. | 193 // Construct a SPDY WINDOW_UPDATE frame. |
190 // Returns the constructed frame. The caller takes ownership of the frame. | 194 // Returns the constructed frame. The caller takes ownership of the frame. |
191 SpdyFrame* ConstructSpdyWindowUpdate(SpdyStreamId, uint32 delta_window_size); | 195 SpdyFrame* ConstructSpdyWindowUpdate(SpdyStreamId, uint32 delta_window_size); |
192 | 196 |
193 // Construct a SPDY RST_STREAM frame. | 197 // Construct a SPDY RST_STREAM frame. |
194 // Returns the constructed frame. The caller takes ownership of the frame. | 198 // Returns the constructed frame. The caller takes ownership of the frame. |
195 SpdyFrame* ConstructSpdyRstStream(SpdyStreamId stream_id, | 199 SpdyFrame* ConstructSpdyRstStream(SpdyStreamId stream_id, |
196 SpdyRstStreamStatus status); | 200 SpdyRstStreamStatus status); |
197 | 201 |
198 // Construct a single SPDY header entry, for validation. | 202 // Construct a single SPDY header entry, for validation. |
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
442 SpdySessionPool* const pool_; | 446 SpdySessionPool* const pool_; |
443 | 447 |
444 DISALLOW_COPY_AND_ASSIGN(SpdySessionPoolPeer); | 448 DISALLOW_COPY_AND_ASSIGN(SpdySessionPoolPeer); |
445 }; | 449 }; |
446 | 450 |
447 } // namespace test_spdy3 | 451 } // namespace test_spdy3 |
448 | 452 |
449 } // namespace net | 453 } // namespace net |
450 | 454 |
451 #endif // NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ | 455 #endif // NET_SPDY_SPDY_TEST_UTIL_SPDY3_H_ |
OLD | NEW |