Documentation ¶
Overview ¶
http2interop document
Index ¶
Constants ¶
View Source
const (
PING_ACK = 0x01
)
View Source
const (
Preface = "PRI * HTTP/2.0\r\n\r\nSM\r\n\r\n"
)
View Source
const (
SETTINGS_ACK = 1
)
View Source
const (
SETTINGS_FLAG_ACK byte = 0x01
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FrameHeader ¶
func (*FrameHeader) MarshalBinary ¶
func (fh *FrameHeader) MarshalBinary() ([]byte, error)
func (*FrameHeader) UnmarshalBinary ¶
func (fh *FrameHeader) UnmarshalBinary(b []byte) error
type FrameType ¶
type FrameType byte
const ( DataFrameType FrameType = 0 HeadersFrameType FrameType = 1 PriorityFrameType FrameType = 2 ResetStreamFrameType FrameType = 3 SettingsFrameType FrameType = 4 PushPromiseFrameType FrameType = 5 PingFrameType FrameType = 6 GoAwayFrameType FrameType = 7 WindowUpdateFrameType FrameType = 8 ContinuationFrameType FrameType = 9 // HTTP1FrameType is not a real type, but rather a convenient way to check if the response // is an http response. The type of a frame header is the 4th byte, which in an http1 // response will be "HTTP/1.1 200 OK" or something like that. The character for "P" is 80. HTTP1FrameType FrameType = 80 )
Types
type GoAwayFrame ¶
type GoAwayFrame struct { Header FrameHeader Reserved StreamID // TODO(carl-mastrangelo): make an enum out of this. Code uint32 Data []byte }
func (*GoAwayFrame) GetHeader ¶
func (f *GoAwayFrame) GetHeader() *FrameHeader
func (*GoAwayFrame) MarshalBinary ¶
func (f *GoAwayFrame) MarshalBinary() ([]byte, error)
func (*GoAwayFrame) MarshalPayload ¶
func (f *GoAwayFrame) MarshalPayload() ([]byte, error)
func (*GoAwayFrame) ParsePayload ¶
func (f *GoAwayFrame) ParsePayload(r io.Reader) error
func (*GoAwayFrame) UnmarshalPayload ¶
func (f *GoAwayFrame) UnmarshalPayload(raw []byte) error
type HTTP1Frame ¶
type HTTP1Frame struct { Header FrameHeader Data []byte }
HTTP1Frame is not a real frame, but rather a way to represent an http1.x response.
func (*HTTP1Frame) GetHeader ¶
func (f *HTTP1Frame) GetHeader() *FrameHeader
func (*HTTP1Frame) MarshalBinary ¶
func (f *HTTP1Frame) MarshalBinary() ([]byte, error)
func (*HTTP1Frame) MarshalPayload ¶
func (f *HTTP1Frame) MarshalPayload() ([]byte, error)
func (*HTTP1Frame) ParsePayload ¶
func (f *HTTP1Frame) ParsePayload(r io.Reader) error
func (*HTTP1Frame) String ¶
func (f *HTTP1Frame) String() string
type HTTP2InteropCtx ¶
type PingFrame ¶
type PingFrame struct { Header FrameHeader Data []byte }
func (*PingFrame) GetHeader ¶
func (f *PingFrame) GetHeader() *FrameHeader
func (*PingFrame) MarshalBinary ¶
func (*PingFrame) MarshalPayload ¶
func (*PingFrame) UnmarshalPayload ¶
type SettingsFrame ¶
type SettingsFrame struct { Header FrameHeader Params []SettingsParameter }
func (*SettingsFrame) GetHeader ¶
func (f *SettingsFrame) GetHeader() *FrameHeader
func (*SettingsFrame) MarshalBinary ¶
func (f *SettingsFrame) MarshalBinary() ([]byte, error)
func (*SettingsFrame) MarshalPayload ¶
func (f *SettingsFrame) MarshalPayload() ([]byte, error)
func (*SettingsFrame) ParsePayload ¶
func (f *SettingsFrame) ParsePayload(r io.Reader) error
func (*SettingsFrame) UnmarshalPayload ¶
func (f *SettingsFrame) UnmarshalPayload(raw []byte) error
type SettingsIdentifier ¶
type SettingsIdentifier uint16
const ( SettingsHeaderTableSize SettingsIdentifier = 1 SettingsEnablePush SettingsIdentifier = 2 SettingsMaxConcurrentStreams SettingsIdentifier = 3 SettingsInitialWindowSize SettingsIdentifier = 4 SettingsMaxFrameSize SettingsIdentifier = 5 SettingsMaxHeaderListSize SettingsIdentifier = 6 )
func (SettingsIdentifier) String ¶
func (si SettingsIdentifier) String() string
type SettingsParameter ¶
type SettingsParameter struct { Identifier SettingsIdentifier Value uint32 }
type UnknownFrame ¶
type UnknownFrame struct { Header FrameHeader Data []byte }
func (*UnknownFrame) GetHeader ¶
func (f *UnknownFrame) GetHeader() *FrameHeader
func (*UnknownFrame) MarshalBinary ¶
func (f *UnknownFrame) MarshalBinary() ([]byte, error)
func (*UnknownFrame) MarshalPayload ¶
func (f *UnknownFrame) MarshalPayload() ([]byte, error)
func (*UnknownFrame) ParsePayload ¶
func (f *UnknownFrame) ParsePayload(r io.Reader) error
func (*UnknownFrame) UnmarshalPayload ¶
func (f *UnknownFrame) UnmarshalPayload(raw []byte) error
Click to show internal directories.
Click to hide internal directories.