file

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NameFormatterDefault

func NameFormatterDefault() (name string, expire int64)

NameFormatterDefault 默认日志文件,每日一份

Types

type Backup

type Backup struct {
	// contains filtered or unexported fields
}

func NewBackup

func NewBackup() *Backup

func (*Backup) Handle

func (b *Backup) Handle(f func() error) (err error)

type NameFormatter

type NameFormatter func() (name string, expire int64)

type Status

type Status struct {
	File   *os.File
	Size   int64 //当前大小
	Expire int64 //过期时间
}

func NewStatus

func NewStatus(f *os.File, expire int64) *Status

Jump to

Keyboard shortcuts

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