file

package
v0.0.0-...-15ea2ad Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2018 License: BSD-3-Clause Imports: 13 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// FancyFormatter is the default formatter for fancy messages.
	FileFormatter = log.MustStringFormatter(`[{{formatTime .Timestamp "2006-01-02 15:04:05"}}] [{{ .ShortFile }}] {{ .LevelIcon }} {{ .LevelTitle }}{{"\t"}}> {{ .Message }}{{ .ParsedFields }}`)
)

Functions

This section is empty.

Types

type Config

type Config struct {
	Filename string
	Folder   string
	MaxSize  int64
	MaxLines int64
}

type File

type File struct {
	Formatter log.Formatter
	// contains filtered or unexported fields
}

func NewFile

func NewFile(config *Config) *File

func (*File) Write

func (c *File) Write(e *log.Entry, calldepth int) error

Jump to

Keyboard shortcuts

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