trace

package
v0.1.13 Latest Latest
Warning

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

Go to latest
Published: May 8, 2018 License: Apache-2.0 Imports: 4 Imported by: 83

Documentation

Index

Constants

This section is empty.

Variables

Logger instance used by trace to log messages.

Functions

func Disable

func Disable()

Disable global tracing.

func Enable

func Enable()

Enable global tracing.

func End

func End(t *Message)

End ends the trace.

func Trace

func Trace(msg string) func()

Trace encapsulates begin and end can be called like: defer trace.Trace("method name")()

func Tracef

func Tracef(format string, a ...interface{}) func()

Tracef encapsulates begin and end can be called like: defer trace.Tracef("method name %s", param)() Like Trace but takes a format string and parameters.

Types

type Message

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

Message is a trace object used to grab run-time state

func Begin

func Begin(msg string) *Message

Begin starts the trace. Msg is the msg to log.

Jump to

Keyboard shortcuts

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