base64

package
v2.0.21 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InvalidEncoding = iota
	Std
	URL
	RawStd
	RawURL
)

Variables

This section is empty.

Functions

func Decode

func Decode(src []byte) ([]byte, error)

func DecodeString

func DecodeString(src string) ([]byte, error)

func Encode

func Encode(src []byte) []byte

func EncodeToString

func EncodeToString(src []byte) string

func EncodeUint64ToString

func EncodeUint64ToString(v uint64) string

func Guess added in v2.0.10

func Guess(src []byte) int

func SetDecoder added in v2.0.10

func SetDecoder(dec Decoder)

func SetEncoder added in v2.0.10

func SetEncoder(enc Encoder)

Types

type Decoder added in v2.0.10

type Decoder interface {
	Decode([]byte) ([]byte, error)
}

type Encoder added in v2.0.10

type Encoder interface {
	Encode([]byte, []byte)
	EncodedLen(int) int
	EncodeToString([]byte) string
}

Jump to

Keyboard shortcuts

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