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

Side by Side Diff: net/spdy/core/spdy_alt_svc_wire_format.h

Issue 2839373002: Implement SPDY_EXPORT and SPDY_EXPORT_PRIVATE macros. (Closed)
Patch Set: Rebase: manually resolve trivial merge conflicts. Created 3 years, 7 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 | « net/spdy/core/hpack/hpack_static_table.h ('k') | net/spdy/core/spdy_frame_builder.h » ('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) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 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 // This file contains data structures and utility functions used for serializing 5 // This file contains data structures and utility functions used for serializing
6 // and parsing alternative service header values, common to HTTP/1.1 header 6 // and parsing alternative service header values, common to HTTP/1.1 header
7 // fields and HTTP/2 and QUIC ALTSVC frames. See specification at 7 // fields and HTTP/2 and QUIC ALTSVC frames. See specification at
8 // https://httpwg.github.io/http-extensions/alt-svc.html. 8 // https://httpwg.github.io/http-extensions/alt-svc.html.
9 9
10 #ifndef NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_ 10 #ifndef NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_
11 #define NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_ 11 #define NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_
12 12
13 #include <cstdint> 13 #include <cstdint>
14 #include <vector> 14 #include <vector>
15 15
16 #include "net/base/net_export.h" 16 #include "net/spdy/platform/api/spdy_export.h"
17 #include "net/spdy/platform/api/spdy_string.h" 17 #include "net/spdy/platform/api/spdy_string.h"
18 #include "net/spdy/platform/api/spdy_string_piece.h" 18 #include "net/spdy/platform/api/spdy_string_piece.h"
19 19
20 namespace net { 20 namespace net {
21 21
22 namespace test { 22 namespace test {
23 class SpdyAltSvcWireFormatPeer; 23 class SpdyAltSvcWireFormatPeer;
24 } // namespace test 24 } // namespace test
25 25
26 class NET_EXPORT_PRIVATE SpdyAltSvcWireFormat { 26 class SPDY_EXPORT_PRIVATE SpdyAltSvcWireFormat {
27 public: 27 public:
28 using VersionVector = std::vector<uint16_t>; 28 using VersionVector = std::vector<uint16_t>;
29 29
30 struct NET_EXPORT_PRIVATE AlternativeService { 30 struct SPDY_EXPORT_PRIVATE AlternativeService {
31 SpdyString protocol_id; 31 SpdyString protocol_id;
32 SpdyString host; 32 SpdyString host;
33 33
34 // Default is 0: invalid port. 34 // Default is 0: invalid port.
35 uint16_t port = 0; 35 uint16_t port = 0;
36 // Default is one day. 36 // Default is one day.
37 uint32_t max_age = 86400; 37 uint32_t max_age = 86400;
38 // Default is empty: unspecified version. 38 // Default is empty: unspecified version.
39 VersionVector version; 39 VersionVector version;
40 40
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 SpdyStringPiece::const_iterator end, 78 SpdyStringPiece::const_iterator end,
79 uint16_t* value); 79 uint16_t* value);
80 static bool ParsePositiveInteger32(SpdyStringPiece::const_iterator c, 80 static bool ParsePositiveInteger32(SpdyStringPiece::const_iterator c,
81 SpdyStringPiece::const_iterator end, 81 SpdyStringPiece::const_iterator end,
82 uint32_t* value); 82 uint32_t* value);
83 }; 83 };
84 84
85 } // namespace net 85 } // namespace net
86 86
87 #endif // NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_ 87 #endif // NET_SPDY_CORE_SPDY_ALT_SVC_WIRE_FORMAT_H_
OLDNEW
« no previous file with comments | « net/spdy/core/hpack/hpack_static_table.h ('k') | net/spdy/core/spdy_frame_builder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698