package qpack
Import Path
github.com/quic-go/qpack (on go.dev)
Dependency Relation
imports 4 packages, and imported by one package
Package-Level Type Names (total 4)
DecodeFunc is a function that decodes the next header field from a header block.
It should be called repeatedly until it returns io.EOF.
It returns io.EOF when all header fields have been decoded.
Any error other than io.EOF indicates a decoding error.
func (*Decoder).Decode(p []byte) DecodeFunc
A Decoder decodes QPACK header blocks.
A Decoder can be reused to decode multiple header blocks on different streams
on the same connection (e.g., headers then trailers).
This will be useful when dynamic table support is added.
Decode returns a function that decodes header fields from the given header block.
It does not copy the slice; the caller must ensure it remains valid during decoding.
func NewDecoder() *Decoder
An Encoder performs QPACK encoding.
Close declares that the encoding is complete and resets the Encoder
to be reused again for a new header block.
WriteField encodes f into a single Write to e's underlying Writer.
This function may also produce bytes for the Header Block Prefix
if necessary. If produced, it is done before encoding f.
*Encoder : github.com/prometheus/common/expfmt.Closer
*Encoder : io.Closer
func NewEncoder(w io.Writer) *Encoder
A HeaderField is a name-value pair. Both the name and value are
treated as opaque sequences of octets.
Name string
Value string
IsPseudo reports whether the header field is an HTTP3 pseudo header.
That is, it reports whether it starts with a colon.
It is not otherwise guaranteed to be a valid pseudo header field,
though.
func (*Encoder).WriteField(f HeaderField) error
Package-Level Functions (total 2)
NewDecoder returns a new Decoder.
NewEncoder returns a new Encoder which performs QPACK encoding. An
encoded data is written to w.
![]() |
The pages are generated with Golds v0.8.2. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |