utilities

package
v0.0.0-...-465877c Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2018 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UTF8 = iota
)

The string encoding options. Currently only support UTF-8. Don't really see the merit in supporting anything else at the moment.

Variables

View Source
var ErrInvalidEncodingType = errors.New("sdbot/utilities: invalid string encoding type")

ErrInvalidEncodingType is returned when the encoding type is not one that is supported.

Functions

func Encode

func Encode(s string, encoding int) (string, error)

Encode returns a strings that is encoded in the provided encoding type. If the encoding type is invalid then we return the original string, but also return an error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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