logop

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLoggerOptions

func NewLoggerOptions(options []LoggerOption) *loggerOptions

NewLoggerOptions creates a loggerOptions from given LoggerOption-s.

Types

type LoggerOption

type LoggerOption func(*loggerOptions)

LoggerOption represents an option for loggerOptions, created by WithXXX functions.

func WithExtraFields

func WithExtraFields(fields map[string]interface{}) LoggerOption

WithExtraFields creates a logop.LoggerOption to log with extra fields.

func WithExtraFieldsV

func WithExtraFieldsV(fields ...interface{}) LoggerOption

WithExtraFieldsV creates a logop.LoggerOption to log with extra fields in vararg.

func WithExtraText

func WithExtraText(text string) LoggerOption

WithExtraText creates a logop.LoggerOption to log with extra text.

Jump to

Keyboard shortcuts

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