decoder

package
Version: v0.0.0-...-2e820b9 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Base64Encoding = base64.StdEncoding

Functions

func Register

func Register(dec Decoder)

func RegisterAlias

func RegisterAlias(name string, dec Decoder)

Types

type Base64

type Base64 struct{}

func (Base64) Decode

func (d Base64) Decode(input io.Reader) (data []byte, err error)

func (Base64) Name

func (d Base64) Name() string

type Decoder

type Decoder interface {
	Name() string
	Decode(input io.Reader) (data []byte, err error)
}

func Get

func Get(name string) (dec Decoder, ok bool)

type Hex

type Hex struct{}

func (Hex) Decode

func (d Hex) Decode(input io.Reader) (data []byte, err error)

func (Hex) Name

func (d Hex) Name() string

type Raw

type Raw struct{}

func (Raw) Decode

func (d Raw) Decode(input io.Reader) (data []byte, err error)

func (Raw) Name

func (d Raw) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL