log

package
v0.1.65 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2023 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultLogger

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

func (*DefaultLogger) Ban

func (d *DefaultLogger) Ban(loginType string, id interface{}, service string, level int, time int64)

func (*DefaultLogger) CloseSafe added in v0.0.9

func (d *DefaultLogger) CloseSafe(loginType string, token string, service string)

func (*DefaultLogger) Enable

func (d *DefaultLogger) Enable(bool bool)

func (*DefaultLogger) IsEnabled

func (d *DefaultLogger) IsEnabled() bool

func (*DefaultLogger) Kickout

func (d *DefaultLogger) Kickout(loginType string, id interface{}, tokenValue string)

func (*DefaultLogger) Login

func (d *DefaultLogger) Login(loginType string, id interface{}, tokenValue string, loginModel *model.Login)

func (*DefaultLogger) Logout

func (d *DefaultLogger) Logout(loginType string, id interface{}, tokenValue string)

func (*DefaultLogger) OpenSafe added in v0.0.9

func (d *DefaultLogger) OpenSafe(loginType string, token string, service string, time int64)

func (*DefaultLogger) RefreshToken

func (d *DefaultLogger) RefreshToken(tokenValue string, id interface{}, timeout int64)

func (*DefaultLogger) Replace

func (d *DefaultLogger) Replace(loginType string, id interface{}, tokenValue string)

func (*DefaultLogger) StartCleanTimer

func (d *DefaultLogger) StartCleanTimer(period int64)

func (*DefaultLogger) UnBan

func (d *DefaultLogger) UnBan(loginType string, id interface{}, service string)

type Logger

type Logger interface {
	persist.Watcher

	// Enable turn on or off
	Enable(bool bool)

	// IsEnabled return if logger is enabled
	IsEnabled() bool

	// StartCleanTimer log after start clean timer
	StartCleanTimer(period int64)
}

Jump to

Keyboard shortcuts

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