context

package
v0.0.0-...-7d5614f Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2014 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GoRoutineID

func GoRoutineID() int64

func LogBmark

func LogBmark(text string)

Shortcut to log some text with the bookmark type

func LogClear

func LogClear(text string)

Shortcut to log some text with the event-clear type

func LogEnder

func LogEnder(text string)

Shortcut to log some text with the event-end (error) type

func LogEndok

func LogEndok(text string)

Shortcut to log some text with the event-end (success) type

func LogMsg

func LogMsg(function, text, msgType string)

Log a bit of text with a given type

func LogStart

func LogStart(text string, bookmark, clear bool)

Shortcut to log some text with the event-start type

func SetLogFile

func SetLogFile(logUrl string)

Set where to log to

func SetLogStream

func SetLogStream(out io.Writer)

Types

type LockWrapper

type LockWrapper struct {
	Wrapped sync.Locker
	LockID  string
	Name    string
}

A class which adds lock block / acquire / release events to the event stream.

Regular code:

foo = sync.Lock()
foo.Lock()
foo.Unlock()

Annotated code:

foo = ctx.LockWrapper{sync.Lock(), "<uuid>", "My Lock"}
foo.Lock()
foo.Unlock()

func (*LockWrapper) Lock

func (self *LockWrapper) Lock()

func (*LockWrapper) Unlock

func (self *LockWrapper) Unlock()

Jump to

Keyboard shortcuts

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