base100

package
v1.0.2006 Latest Latest
Warning

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

Go to latest
Published: May 11, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidData = InvalidInputError{"data is invalid"}

ErrInvalidData is returned if data is not a valid base100 string

View Source
var ErrInvalidLength = InvalidInputError{"len(data) should be divisible by 4"}

ErrInvalidLength is returned when length of string being decoded is not divisible by four

Functions

func Decode

func Decode(data string) ([]byte, error)

Decode transforms base100 utf-8 encoded string into bytes

func Encode

func Encode(data []byte) string

Encode tranforms bytes into base100 utf-8 encoded string

Types

type InvalidInputError

type InvalidInputError struct {
	// contains filtered or unexported fields
}

InvalidInputError is returned when Decode fails

func (InvalidInputError) Error

func (e InvalidInputError) Error() string

Jump to

Keyboard shortcuts

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