log

package
v0.0.0-...-c0a90d8 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2017 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() *logger

Types

type Field

type Field = zapcore.Field

func Any

func Any(key string, val interface{}) Field

func Duration

func Duration(key string, val time.Duration) Field

func Error

func Error(key string, val error) Field

func Int

func Int(key string, val int) Field

func Int16

func Int16(key string, val int16) Field

func Int32

func Int32(key string, val int32) Field

func Int64

func Int64(key string, val int64) Field

func String

func String(key string, val string) Field

func Uint32

func Uint32(key string, val uint32) Field

type Logger

type Logger interface {
	// Use Debug if you want your logs running in development, testing,
	// production.
	Debug(msg string, fields ...Field)
	// Use Info if you want your logs running in production.
	Info(msg string, fields ...Field)
	// Use Error if you want your logs running in production and you have an error.
	Error(msg string, fields ...Field)

	With(...Field) *logger
}

Jump to

Keyboard shortcuts

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