level

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrIllegalLevel = errors.New("illegal level")
)

Functions

This section is empty.

Types

type Names

type Names interface {
	FromOrdinal(uint16) (string, error)
	ToOrdinal(string) (uint16, error)
}
var DefaultLevelNames Names = &defaultNames{}

type NamesAware

type NamesAware interface {
	GetLevelNames() Names
}

type Serializable

type Serializable interface {
	encoding.TextMarshaler
	encoding.TextUnmarshaler
	fmt.Stringer
	flag.Value

	AsLevel() *log.Level
}

func AsSerializable

func AsSerializable(level *log.Level, aware NamesAware) Serializable

Jump to

Keyboard shortcuts

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