http2

package
v3.47.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 10, 2024 License: MIT Imports: 1 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PriorityFrame

type PriorityFrame struct {
	StreamID      uint32
	PriorityParam PriorityParam
}

PriorityFrame represents a http priority frame.

type PriorityParam

type PriorityParam struct {
	// StreamDep is a 31-bit stream identifier for the
	// stream that this stream depends on. Zero means no
	// dependency.
	StreamDep uint32

	// Exclusive is whether the dependency is exclusive.
	Exclusive bool

	// Weight is the stream's zero-indexed weight. It should be
	// set together with StreamDep, or neither should be set. Per
	// the spec, "Add one to the value to obtain a weight between
	// 1 and 256."
	Weight uint8
}

PriorityParam are the stream prioritzation parameters.

func (PriorityParam) IsZero

func (p PriorityParam) IsZero() bool

type Setting

type Setting struct {
	// ID is which setting is being set.
	// See https://httpwg.org/specs/rfc7540.html#SettingValues
	ID SettingID

	// Val is the value.
	Val uint32
}

Setting is a setting parameter: which setting it is, and its value.

func (Setting) String

func (s Setting) String() string

type SettingID

type SettingID uint16

A SettingID is an HTTP/2 setting as defined in https://httpwg.org/specs/rfc7540.html#iana-settings

const (
	SettingHeaderTableSize      SettingID = 0x1
	SettingEnablePush           SettingID = 0x2
	SettingMaxConcurrentStreams SettingID = 0x3
	SettingInitialWindowSize    SettingID = 0x4
	SettingMaxFrameSize         SettingID = 0x5
	SettingMaxHeaderListSize    SettingID = 0x6
)

func (SettingID) String

func (s SettingID) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL