strconv

package
v1.48.2 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2022 License: OSL-3.0 Imports: 2 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendCardinal added in v1.47.8

func AppendCardinal[T Ordered](b []byte, value T) []byte

func AppendInt

func AppendInt[T Signed](b []byte, value T, base int) []byte

func AppendQuote

func AppendQuote[T String](b []byte, value T) []byte

func AppendSize added in v1.47.8

func AppendSize[T Integer](b []byte, value T) []byte

func AppendUint

func AppendUint[T Unsigned](b []byte, value T, base int) []byte

func Valid added in v1.47.6

func Valid(b []byte) bool

mimesniff.spec.whatwg.org#binary-data-byte

Types

type Integer added in v1.47.8

type Integer interface {
	Signed | Unsigned
}

type Ordered

type Ordered interface {
	Integer | ~float32 | ~float64
}

type Ratio added in v1.47.8

type Ratio float64

func NewRatio added in v1.47.8

func NewRatio[T, U Ordered](value T, total U) Ratio

func (Ratio) AppendPercent added in v1.47.8

func (r Ratio) AppendPercent(b []byte) []byte

func (Ratio) AppendRate added in v1.47.8

func (r Ratio) AppendRate(b []byte) []byte

type Signed added in v1.47.6

type Signed interface {
	~int | ~int8 | ~int16 | ~int32 | ~int64
}

type String

type String interface {
	~[]byte | ~[]rune | ~byte | ~rune | ~string
}

type Unsigned added in v1.47.6

type Unsigned interface {
	~uint | ~uint8 | ~uint16 | ~uint32 | ~uint64 | ~uintptr
}

Jump to

Keyboard shortcuts

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