log

package module
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2025 License: MIT Imports: 12 Imported by: 0

README

Mulan-Ext Log

使用

go get https://github.com/mulan-ext/log.git

许可证

本项目基于 MIT 开源。

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FlagSet

func FlagSet() *pflag.FlagSet

func New

func New(isDev bool, name ...string) (*zap.Logger, error)

func NewWithConfig

func NewWithConfig(cfg *Config, name ...string) (*zap.Logger, error)

Types

type Config

type Config struct {
	IsDev    bool     `json:"is_dev" yaml:"is_dev"`
	Level    string   `json:"level" yaml:"level"`
	Adaptors []string `json:"adaptors,omitzero" yaml:"adaptors"`
}

func (*Config) FlagSet added in v0.1.2

func (c *Config) FlagSet() *pflag.FlagSet

type FileWriter

type FileWriter struct{}

type HTTPWriter

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

func (*HTTPWriter) Sync

func (w *HTTPWriter) Sync() error

func (*HTTPWriter) Write

func (w *HTTPWriter) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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