logger

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package logger is the package that provides logging functionality.

Package logger is the package that provides logging functionality.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FxeventLogger

type FxeventLogger struct {
	Logger Logger
}

FxeventLogger is a wrapper around the Logger interface that implements the fxevent.Logger interface.

func (*FxeventLogger) LogEvent

func (l *FxeventLogger) LogEvent(event fxevent.Event)

LogEvent is called by the fx library to log events. nolint:funlen

type Logger

type Logger interface {
	// Debug logs a message with some additional context.
	Debug(string, ...any)

	// DPanic logs a message with some additional context. In development mode, the logger then panics.
	DPanic(string, ...any)

	// Info logs a message with some additional context.
	Info(string, ...any)

	// Warn logs a message with some additional context.
	Warn(string, ...any)

	// Error logs a message with some additional context.
	Error(string, ...any)

	// Fatal logs a message with some additional context, then calls os.Exit.
	Fatal(string, ...any)

	// Panic logs a message with some additional context, then panics.
	Panic(string, ...any)

	// Close closes the logger.
	Close() error
}

Logger is the interface that wraps the basic logging methods.

Directories

Path Synopsis
Package asynczap is the package that provides the AsyncZap logger.
Package asynczap is the package that provides the AsyncZap logger.
Package zap is the package that provides the Zap logger.
Package zap is the package that provides the Zap logger.

Jump to

Keyboard shortcuts

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