console

package
v2.5.1 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package console 输出到控制台的日志

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPrinter added in v2.4.0

func NewPrinter(tag language.Tag) (*message.Printer, error)

func Visiter added in v2.3.0

func Visiter(next http.Handler, p *message.Printer, succ, erro *Logger) http.Handler

Types

type Logger

type Logger struct {
	Colorize *colors.Colorize
	Prefix   string
	Color    colors.Color
}

Logger 输出到控制台的日志

func (*Logger) AsLogger

func (l *Logger) AsLogger() *log.Logger

func (*Logger) Printf

func (l *Logger) Printf(format string, v ...interface{})

func (*Logger) Println

func (l *Logger) Println(v ...interface{})

func (*Logger) Write

func (l *Logger) Write(bs []byte) (int, error)

Jump to

Keyboard shortcuts

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