headers

package
v0.0.0-...-a26ebea Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2022 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Headers

type Headers []header.Header

Headers represents an ordered slice of header.Header structs.

func Generate

func Generate(rand *rand.Rand) Headers

Generate a random Headers value.

func New

func New(headers []header.Header) (Headers, validation.ErrorGroup)

New creates and validates new Headers from the given slice of header.Header.

func (Headers) Check

func (h Headers) Check() validation.ErrorGroup

Check runs default validation checks for the Headers.

func (Headers) Equals

func (h Headers) Equals(v any) bool

Equals compares two Headers instances for equality.

Interface: comparison.Equaler

func (Headers) Generate

func (Headers) Generate(rand *rand.Rand, size int) reflect.Value

Generate random Headers values.

Interface: quick.Generator

func (Headers) MarshalBinary

func (h Headers) MarshalBinary() (data []byte, err error)

MarshalBinary converts the Headers instance to binary form.

Interface: encoding.BinaryMarshaler

func (Headers) MarshalBinaryWriter

func (h Headers) MarshalBinaryWriter(w io.Writer) (err error)

MarshalBinaryWriter populates the io.Writer with Headers data in its binary form.

func (Headers) String

func (h Headers) String() string

String value of the Headers.

Interface: fmt.Stringer.

func (*Headers) UnmarshalBinary

func (h *Headers) UnmarshalBinary(data []byte) (err error)

UnmarshalBinary converts the binary form to a Headers instance.

Interface: encoding.BinaryUnmarshaler

func (*Headers) UnmarshalBinaryReader

func (h *Headers) UnmarshalBinaryReader(r io.Reader) (err error)

UnmarshalBinaryReader populates Headers from an io.Reader returning the binary form.

Jump to

Keyboard shortcuts

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