log

package
v0.1.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Verbose bool

Functions

func Fail

func Fail()

func FormatJson

func FormatJson(s string) (string, error)

func FormatMap

func FormatMap(m map[string]string) (string, error)

func Info

func Info(v ...interface{})

func Printf

func Printf(format string, v ...interface{})

func Println

func Println(v ...interface{})

func SetDefaultLogger

func SetDefaultLogger(l Logger)

SetDefaultLogger sets the default logger.

func Success

func Success()

func Warn

func Warn(v ...interface{})

func Warnf

func Warnf(format string, v ...interface{})

Types

type JsonFormatter

type JsonFormatter struct{}

func (*JsonFormatter) Format

func (jf *JsonFormatter) Format(s string) (string, error)

type Logger

type Logger struct {
	Println func(w io.Writer, a ...interface{}) (n int, err error)
	Printf  func(w io.Writer, format string, a ...interface{}) (n int, err error)
}

type MapFormatter

type MapFormatter struct{}

func (*MapFormatter) Format

func (mf *MapFormatter) Format(m map[string]string) (string, error)

Jump to

Keyboard shortcuts

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