OLD | NEW |
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2016 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_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ | 5 #ifndef NET_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ |
6 #define NET_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ | 6 #define NET_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ |
7 | 7 |
8 #include "net/base/net_export.h" | |
9 #include "net/quic/core/quic_error_codes.h" | 8 #include "net/quic/core/quic_error_codes.h" |
10 #include "net/quic/core/quic_types.h" | 9 #include "net/quic/core/quic_types.h" |
| 10 #include "net/quic/platform/api/quic_export.h" |
11 | 11 |
12 namespace net { | 12 namespace net { |
13 | 13 |
14 struct NET_EXPORT_PRIVATE QuicRstStreamFrame { | 14 struct QUIC_EXPORT_PRIVATE QuicRstStreamFrame { |
15 QuicRstStreamFrame(); | 15 QuicRstStreamFrame(); |
16 QuicRstStreamFrame(QuicStreamId stream_id, | 16 QuicRstStreamFrame(QuicStreamId stream_id, |
17 QuicRstStreamErrorCode error_code, | 17 QuicRstStreamErrorCode error_code, |
18 QuicStreamOffset bytes_written); | 18 QuicStreamOffset bytes_written); |
19 | 19 |
20 friend NET_EXPORT_PRIVATE std::ostream& operator<<( | 20 friend QUIC_EXPORT_PRIVATE std::ostream& operator<<( |
21 std::ostream& os, | 21 std::ostream& os, |
22 const QuicRstStreamFrame& r); | 22 const QuicRstStreamFrame& r); |
23 | 23 |
24 QuicStreamId stream_id; | 24 QuicStreamId stream_id; |
25 QuicRstStreamErrorCode error_code; | 25 QuicRstStreamErrorCode error_code; |
26 | 26 |
27 // Used to update flow control windows. On termination of a stream, both | 27 // Used to update flow control windows. On termination of a stream, both |
28 // endpoints must inform the peer of the number of bytes they have sent on | 28 // endpoints must inform the peer of the number of bytes they have sent on |
29 // that stream. This can be done through normal termination (data packet with | 29 // that stream. This can be done through normal termination (data packet with |
30 // FIN) or through a RST. | 30 // FIN) or through a RST. |
31 QuicStreamOffset byte_offset; | 31 QuicStreamOffset byte_offset; |
32 }; | 32 }; |
33 | 33 |
34 } // namespace net | 34 } // namespace net |
35 | 35 |
36 #endif // NET_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ | 36 #endif // NET_QUIC_CORE_FRAMES_QUIC_RST_STREAM_FRAME_H_ |
OLD | NEW |