rotate

package
v4.0.0-...-5981c31 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: BSD-2-Clause, BSD-2-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrAlreadyClosed = errors.New("already closed")
)

Functions

This section is empty.

Types

type FileRotator

type FileRotator struct {
	sync.Mutex
	// contains filtered or unexported fields
}

func Open

func Open(pth string, perm os.FileMode) (*FileRotator, error)

func OpenEx

func OpenEx(pth string, perm os.FileMode, maxSize int64, maxHistory uint, compressOld bool) (*FileRotator, error)

func (*FileRotator) Close

func (fr *FileRotator) Close() (err error)

func (*FileRotator) Write

func (fr *FileRotator) Write(buf []byte) (n int, err error)

Jump to

Keyboard shortcuts

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