TimedRotatingFileHook

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NewWriterErr

type NewWriterErr struct {
	Errs []error
}

func (*NewWriterErr) AddErr

func (e *NewWriterErr) AddErr(err error)

func (NewWriterErr) Error

func (e NewWriterErr) Error() string

type TRFileHook

type TRFileHook struct {
	MainWriter     *os.File
	ErrWriter      *os.File
	MainDateWriter *os.File
	ErrDateWriter  *os.File

	NowTime     time.Time
	When        string
	FileName    string
	FileErrName string
	FilePath    string
	FilePrefix  string
	// contains filtered or unexported fields
}

func NewTRFileHook

func NewTRFileHook(logdir, filename, when string) (*TRFileHook, error)

func NewTRFileHookHostname

func NewTRFileHookHostname(logdir, filename, when string) (*TRFileHook, error)

func (*TRFileHook) CloseWrites

func (h *TRFileHook) CloseWrites()

func (*TRFileHook) Fire

func (h *TRFileHook) Fire(entry *logrus.Entry) error

func (*TRFileHook) Levels

func (h *TRFileHook) Levels() []logrus.Level

func (*TRFileHook) SetFilePrefix

func (h *TRFileHook) SetFilePrefix(fp string)

type WriteErr

type WriteErr struct {
	Errs []error
}

func (*WriteErr) AddErr

func (e *WriteErr) AddErr(err error)

func (WriteErr) Error

func (e WriteErr) Error() string

Jump to

Keyboard shortcuts

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