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

Side by Side Diff: net/spdy/spdy_protocol.h

Issue 246013002: SPDY: Headers & Push-Promise now use Continuations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase only Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « net/spdy/spdy_framer_test.cc ('k') | net/spdy/spdy_protocol.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 // This file contains some protocol structures for use with SPDY 2 and 3 5 // This file contains some protocol structures for use with SPDY 2 and 3
6 // The SPDY 2 spec can be found at: 6 // The SPDY 2 spec can be found at:
7 // http://dev.chromium.org/spdy/spdy-protocol/spdy-protocol-draft2 7 // http://dev.chromium.org/spdy/spdy-protocol/spdy-protocol-draft2
8 // The SPDY 3 spec can be found at: 8 // The SPDY 3 spec can be found at:
9 // http://dev.chromium.org/spdy/spdy-protocol/spdy-protocol-draft3 9 // http://dev.chromium.org/spdy/spdy-protocol/spdy-protocol-draft3
10 10
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 // Behavior is undefined for invalid GOAWAY status fields; consumers should 471 // Behavior is undefined for invalid GOAWAY status fields; consumers should
472 // first use IsValidGoAwayStatus() to verify validity of GOAWAY status fields. 472 // first use IsValidGoAwayStatus() to verify validity of GOAWAY status fields.
473 static SpdyGoAwayStatus ParseGoAwayStatus(SpdyMajorVersion version, 473 static SpdyGoAwayStatus ParseGoAwayStatus(SpdyMajorVersion version,
474 int goaway_status_field); 474 int goaway_status_field);
475 475
476 // Serializes a given GOAWAY status to the on-the-wire enumeration value for 476 // Serializes a given GOAWAY status to the on-the-wire enumeration value for
477 // the given protocol version. 477 // the given protocol version.
478 // Returns -1 on failure (I.E. Invalid GOAWAY status for the given version). 478 // Returns -1 on failure (I.E. Invalid GOAWAY status for the given version).
479 static int SerializeGoAwayStatus(SpdyMajorVersion version, 479 static int SerializeGoAwayStatus(SpdyMajorVersion version,
480 SpdyGoAwayStatus status); 480 SpdyGoAwayStatus status);
481
482 // Size, in bytes, of the data frame header. Future versions of SPDY
483 // will likely vary this, so we allow for the flexibility of a function call
484 // for this value as opposed to a constant.
485 static size_t GetDataFrameMinimumSize();
486
487 // Size, in bytes, of the control frame header.
488 static size_t GetControlFrameHeaderSize(SpdyMajorVersion version);
489
490 static size_t GetPrefixLength(SpdyFrameType type, SpdyMajorVersion version);
491
492 static size_t GetFrameMaximumSize(SpdyMajorVersion version);
481 }; 493 };
482 494
483 class SpdyFrame; 495 class SpdyFrame;
484 typedef SpdyFrame SpdySerializedFrame; 496 typedef SpdyFrame SpdySerializedFrame;
485 497
486 class SpdyFrameVisitor; 498 class SpdyFrameVisitor;
487 499
488 // Intermediate representation for SPDY frames. 500 // Intermediate representation for SPDY frames.
489 // TODO(hkhalil): Rename this class to SpdyFrame when the existing SpdyFrame is 501 // TODO(hkhalil): Rename this class to SpdyFrame when the existing SpdyFrame is
490 // gone. 502 // gone.
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
965 SpdyFrameVisitor() {} 977 SpdyFrameVisitor() {}
966 virtual ~SpdyFrameVisitor() {} 978 virtual ~SpdyFrameVisitor() {}
967 979
968 private: 980 private:
969 DISALLOW_COPY_AND_ASSIGN(SpdyFrameVisitor); 981 DISALLOW_COPY_AND_ASSIGN(SpdyFrameVisitor);
970 }; 982 };
971 983
972 } // namespace net 984 } // namespace net
973 985
974 #endif // NET_SPDY_SPDY_PROTOCOL_H_ 986 #endif // NET_SPDY_SPDY_PROTOCOL_H_
OLDNEW
« no previous file with comments | « net/spdy/spdy_framer_test.cc ('k') | net/spdy/spdy_protocol.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698