formatter

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2017 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Adapters

func Adapters() []string

Adapters returns the list of registered adapters

func New

func New(config *config.Log) (log.Formatter, error)

func Register

func Register(name string, adapter Adapter)

Register makes a logger adapter available by the provided name. If an adapter is registered twice or if an adapter is nil, it will panic.

Types

type Adapter

type Adapter func(config map[string]string) (log.Formatter, error)

Adapter returns a new logger initialised with the given config

Directories

Path Synopsis
Package json is a JSON log formatter.
Package json is a JSON log formatter.
Package logf is a human friendly log formatter.
Package logf is a human friendly log formatter.

Jump to

Keyboard shortcuts

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