Documentation ¶
Overview ¶
Package deferconsole writes data with level filters and defer to stdout/stderr.
Index ¶
Constants ¶
View Source
const ( // DstStdErr write to stderr DstStdErr = iota // DstStdOut write to stdout DstStdOut )
View Source
const ( // LevelKeep don't change level LevelKeep = -3 // LevelSilence supress all output LevelSilence = -2 // LevelRestore disable silence LevelRestore = -1 // LevelSecret prints secrets LevelSecret = 0 // LevelTrace prints traces LevelTrace = 1 // LevelDebug for debugging information LevelDebug = 2 // LevelInfo for general information LevelInfo = 3 // LevelError to print errors LevelError = 4 // LevelData is for data LevelData = 5 // LevelPrint is for normal output LevelPrint = 6 // LevelFatal for fatal erros LevelFatal = 7 )
Variables ¶
View Source
var ( // ToErrors writes string to stderr ToErrors directFunc // ToError writes elements to error ToError stringFunc // ToErrorf writes formatted elements to error ToErrorf formatFunc // Prints writes string to stdout Prints directFunc // Printf writes formatted elements to stdout Printf formatFunc // Print writes elements to stdout Print stringFunc // Infos is info Infos directFunc // Info is info Info stringFunc // Infof is info Infof formatFunc // Debugs is debug Debugs directFunc // Debug is debug Debug stringFunc // Debugf is debug Debugf formatFunc // Errors is error Errors directFunc // Error is error Error stringFunc // Errorf is error Errorf formatFunc // Fatals is fatal Fatals directFunc // Fatal is fatal Fatal stringFunc // Fatalf is fatal Fatalf formatFunc // Traces is trace Traces directFunc // Trace is trace Trace stringFunc // Tracef is trace Tracef formatFunc // Secrets is secret Secrets directFunc // Secret is secret Secret stringFunc // Secretf is secret Secretf formatFunc // Datas is data Datas directFunc // Data is data Data stringFunc // Dataf is data Dataf formatFunc )
Functions ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.