logger

package
v0.0.86 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Logger

type Logger interface {
	// Debug sends out a debug message with the given arguments to the logger.
	Debug(args ...interface{})
	// Debugf formats a debug message using the given arguments and sends it to the logger.
	Debugf(format string, args ...interface{})
	// Info sends out an informational message with the given arguments to the logger.
	Info(args ...interface{})
	// Infof formats an informational message using the given arguments and sends it to the logger.
	Infof(format string, args ...interface{})
	// Warn sends out a warning message with the given arguments to the logger.
	Warn(args ...interface{})
	// Warnf formats a warning message using the given arguments and sends it to the logger.
	Warnf(format string, args ...interface{})
	// Error sends out an error message with the given arguments to the logger.
	Error(args ...interface{})
	// Errorf formats an error message using the given arguments and sends it to the logger.
	Errorf(format string, args ...interface{})
}

Logger is the common interface for user-provided loggers.

type TinyLogger added in v0.0.60

type TinyLogger struct{}

TinyLogger is an _almost_ no-op logger - if the user of the SDK does not inject their own logger, this logger will be used instead. This logger will print Warning and Error messages to STDOUT and will ignore Debug & Info.

func (*TinyLogger) Debug added in v0.0.60

func (l *TinyLogger) Debug(args ...interface{})

Debug won't print anything.

func (*TinyLogger) Debugf added in v0.0.60

func (l *TinyLogger) Debugf(format string, args ...interface{})

Debugf is no-op implementation of Logger's Debugf.

func (*TinyLogger) Error added in v0.0.60

func (l *TinyLogger) Error(args ...interface{})

Error will print the error message to STDOUT. This will only be used if the user has NOT injected their own logger.

func (*TinyLogger) Errorf added in v0.0.60

func (l *TinyLogger) Errorf(format string, args ...interface{})

Errorf will print the error message to STDOUT. This will only be used if the user has NOT injected their own logger.

func (*TinyLogger) Info added in v0.0.60

func (l *TinyLogger) Info(args ...interface{})

Info is no-op implementation of Logger's Info.

func (*TinyLogger) Infof added in v0.0.60

func (l *TinyLogger) Infof(format string, args ...interface{})

Infof is a no-op implementation of Logger's Infof.

func (*TinyLogger) Warn added in v0.0.60

func (l *TinyLogger) Warn(args ...interface{})

Warn will print the warn message to STDOUT. This will only be used if the user has NOT injected their own logger.

func (*TinyLogger) Warnf added in v0.0.60

func (l *TinyLogger) Warnf(format string, args ...interface{})

Warnf will print the warn message to STDOUT. This will only be used if the user has NOT injected their own logger.

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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