logger

package
v1.0.0-beta.4 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DisableLogColor

func DisableLogColor()

func DisablePrettyLog

func DisablePrettyLog()

func EnableLogColor

func EnableLogColor()

func FitText

func FitText(text string, options FitTextOptions) string

func FormattedLogF

func FormattedLogF(w io.Writer, format string, a ...interface{}) (int, error)

func GetErrStream

func GetErrStream() io.Writer

func GetOutStream

func GetOutStream() io.Writer

func IndentDown

func IndentDown()

func IndentUp

func IndentUp()

func Init

func Init()

func IsTerminal

func IsTerminal() bool

func LogErrorF

func LogErrorF(format string, a ...interface{})

func LogErrorLn

func LogErrorLn(a ...interface{})

func LogF

func LogF(format string, a ...interface{})

func LogHighlightF

func LogHighlightF(format string, a ...interface{})

func LogHighlightLn

func LogHighlightLn(a ...interface{})

func LogInfoF

func LogInfoF(format string, a ...interface{})

func LogInfoLn

func LogInfoLn(a ...interface{})

func LogLn

func LogLn(a ...interface{})

func LogProcess

func LogProcess(msg string, options LogProcessOptions, processFunc func() error) error

func LogProcessInline

func LogProcessInline(msg string, processFunc func() error) error

func LogSecondaryProcess

func LogSecondaryProcess(msg string, options LogProcessOptions, processFunc func() error) error

func LogSecondaryProcessInline

func LogSecondaryProcessInline(msg string, processFunc func() error) error

func LogServiceF

func LogServiceF(format string, a ...interface{})

func LogServiceLn

func LogServiceLn(a ...interface{})

func MuteErr

func MuteErr()

func MuteOut

func MuteOut()

func OptionalLnModeOn

func OptionalLnModeOn()

func RawStreamsOutputModeOn

func RawStreamsOutputModeOn()

func SetTag

func SetTag(value string, colorizeFunc func(...interface{}) string)

func TerminalWidth

func TerminalWidth() int

func UnmuteErr

func UnmuteErr()

func UnmuteOut

func UnmuteOut()

func WithFittedStreamsOutputOn

func WithFittedStreamsOutputOn(f func() error) error

func WithIndent

func WithIndent(f func() error) error

func WithRawStreamsOutputModeOn

func WithRawStreamsOutputModeOn(f func() error) error

func WithTag

func WithTag(value string, colorizeFunc func(...interface{}) string, f func() error) error

func WithoutIndent

func WithoutIndent(decoratedFunc func() error) error

Types

type FitTextOptions

type FitTextOptions struct {
	ExtraIndentWidth int
	MaxWidth         int
	MarkWrappedLine  bool
}

type LogProcessOptions

type LogProcessOptions struct {
	WithIndent           bool
	WithoutLogOptionalLn bool
	InfoSectionFunc      func(err error)
	ColorizeMsgFunc      func(...interface{}) string
}

type WriterProxy

type WriterProxy struct {
	io.Writer
}

func (WriterProxy) Write

func (p WriterProxy) Write(data []byte) (int, error)

Jump to

Keyboard shortcuts

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