log

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2014 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrorOutput

func ErrorOutput(str string)

func SystemOutput

func SystemOutput(str string)

Types

type Log

type Log struct {
	Name    string
	Color   ct.Color
	IsError bool
	Factory *LogFactory
}

func (*Log) Println

func (o *Log) Println(str string)

func (*Log) Write

func (o *Log) Write(b []byte) (num int, err error)

Safe (using mutex) writing to a specific log

type LogFactory

type LogFactory struct {
	Logs    map[string]*Log
	Padding int
	Name    string
}
var DefaultFactory *LogFactory

Default factory for creating loggers

func NewLogFactory

func NewLogFactory() (of *LogFactory)

Log factory constructor

func (*LogFactory) CreateLog

func (of *LogFactory) CreateLog(name string, index int, isError bool) *Log

func (*LogFactory) ErrorOutput

func (of *LogFactory) ErrorOutput(str string)

Safe (using mutex) write to error output (from system's name)

func (*LogFactory) SystemOutput

func (of *LogFactory) SystemOutput(str string)

Safe (using mutex) write to output (from system's name)

Jump to

Keyboard shortcuts

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