core

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2022 License: Apache-2.0 Imports: 5 Imported by: 12

Documentation

Index

Constants

View Source
const Inquisitor = "---INQUISITOR---"

Variables

This section is empty.

Functions

func Debug

func Debug(a ...any)

func Debugf

func Debugf(format string, a ...any)

func Error

func Error(a ...any)

func Errorf

func Errorf(format string, a ...any)

func Fatal

func Fatal(a ...any)

func Fatalf

func Fatalf(format string, a ...any)

func Info

func Info(a ...any)

func Infof

func Infof(format string, a ...any)

func SetLevel

func SetLevel(lv Level)

func SetOutput

func SetOutput(w io.Writer)

func Trace

func Trace(a ...any)

func Tracef

func Tracef(format string, a ...any)

func Warn

func Warn(a ...any)

func Warnf

func Warnf(format string, a ...any)

Types

type CommonLogger

type CommonLogger interface {
	Trace(a ...any)
	Debug(a ...any)
	Info(a ...any)
	Warn(a ...any)
	Error(a ...any)
	Fatal(a ...any)
}

type Config

type Config interface {
	SetLevel(lv Level)
	SetOutput(w io.Writer)
}

type FormatLogger

type FormatLogger interface {
	Tracef(format string, a ...any)
	Debugf(format string, a ...any)
	Infof(format string, a ...any)
	Warnf(format string, a ...any)
	Errorf(format string, a ...any)
	Fatalf(format string, a ...any)
}

type ILogger

type ILogger interface {
	CommonLogger
	FormatLogger
	Config
}

type Level

type Level int
const (
	LevelTrace Level = iota
	LevelDebug
	LevelInfo
	LevelWarn
	LevelError
	LevelFatal
)

Jump to

Keyboard shortcuts

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