util

package
v0.0.0-...-0b82c43 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2016 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContextLogger

type ContextLogger struct {
	*logrus.Entry
}

ContextLogger is a wrapper for logrus that defines which package and function a log is written

func NewContextLogger

func NewContextLogger(pkg string) ContextLogger

NewContextLogger returns a new ContextLogger for the given package

func (ContextLogger) InFunc

func (c ContextLogger) InFunc(function string) ContextLogger

InFunc is a helper method to set the func field for the logger

func (ContextLogger) InStruct

func (c ContextLogger) InStruct(s string) ContextLogger

Jump to

Keyboard shortcuts

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