OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #include "net/spdy/spdy_test_util_common.h" | 5 #include "net/spdy/spdy_test_util_common.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <cstddef> | 9 #include <cstddef> |
10 | 10 |
(...skipping 934 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
945 const SpdyStreamId stream_id, uint32 delta_window_size) const { | 945 const SpdyStreamId stream_id, uint32 delta_window_size) const { |
946 SpdyWindowUpdateIR update_ir(stream_id, delta_window_size); | 946 SpdyWindowUpdateIR update_ir(stream_id, delta_window_size); |
947 return CreateFramer(false)->SerializeFrame(update_ir); | 947 return CreateFramer(false)->SerializeFrame(update_ir); |
948 } | 948 } |
949 | 949 |
950 // TODO(jgraettinger): Eliminate uses of this method in tests (prefer | 950 // TODO(jgraettinger): Eliminate uses of this method in tests (prefer |
951 // SpdyRstStreamIR). | 951 // SpdyRstStreamIR). |
952 SpdyFrame* SpdyTestUtil::ConstructSpdyRstStream( | 952 SpdyFrame* SpdyTestUtil::ConstructSpdyRstStream( |
953 SpdyStreamId stream_id, | 953 SpdyStreamId stream_id, |
954 SpdyRstStreamStatus status) const { | 954 SpdyRstStreamStatus status) const { |
955 SpdyRstStreamIR rst_ir(stream_id, status, ""); | 955 SpdyRstStreamIR rst_ir(stream_id, status); |
956 return CreateFramer(false)->SerializeRstStream(rst_ir); | 956 return CreateFramer(false)->SerializeRstStream(rst_ir); |
957 } | 957 } |
958 | 958 |
959 SpdyFrame* SpdyTestUtil::ConstructSpdyGet( | 959 SpdyFrame* SpdyTestUtil::ConstructSpdyGet( |
960 const char* const url, | 960 const char* const url, |
961 bool compressed, | 961 bool compressed, |
962 SpdyStreamId stream_id, | 962 SpdyStreamId stream_id, |
963 RequestPriority request_priority) const { | 963 RequestPriority request_priority) const { |
964 scoped_ptr<SpdyHeaderBlock> block(ConstructGetHeaderBlock(url)); | 964 scoped_ptr<SpdyHeaderBlock> block(ConstructGetHeaderBlock(url)); |
965 return ConstructSpdySyn( | 965 return ConstructSpdySyn( |
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1351 } | 1351 } |
1352 } | 1352 } |
1353 | 1353 |
1354 void SpdyTestUtil::SetPriority(RequestPriority priority, | 1354 void SpdyTestUtil::SetPriority(RequestPriority priority, |
1355 SpdySynStreamIR* ir) const { | 1355 SpdySynStreamIR* ir) const { |
1356 ir->set_priority(ConvertRequestPriorityToSpdyPriority( | 1356 ir->set_priority(ConvertRequestPriorityToSpdyPriority( |
1357 priority, spdy_version())); | 1357 priority, spdy_version())); |
1358 } | 1358 } |
1359 | 1359 |
1360 } // namespace net | 1360 } // namespace net |
OLD | NEW |