Documentation ¶
Overview ¶
Package logs output logs and advanced debug information
Index ¶
- Constants
- Variables
- func DebugLog(args ...interface{})
- func DeleteWriters(writerToDelete io.Writer, logFlags ...FgLogWriter)
- func ErrorLog(err error, args ...interface{})
- func ErrorLogHandler(err error, args ...interface{})
- func ErrorStack(err error, args ...interface{})
- func Fatal(err error, args ...interface{})
- func GetStack(i int, stackLine string) string
- func MultiWriter(writers ...io.Writer) io.Writer
- func NewWrapKitLogger(pref string, depth int) *wrapKitLogger
- func NewlogMess(mess string, logger *wrapKitLogger) *logMess
- func SetDebug(d bool) bool
- func SetLogFlags(f int) int
- func SetSentry(dns string, org string) error
- func SetStackBeginWith(s int) int
- func SetStatus(s bool) bool
- func SetWriters(newWriter io.Writer, logFlags ...FgLogWriter)
- func StatusLog(args ...interface{})
- func TraceLog(args ...interface{})
- type FgLogWriter
- type Level
- type LogsType
- type MultiwriterErr
- type WriterErr
Constants ¶
View Source
const ( LogPutColor = "\033[" LogEndColor = "\033[0m" )
Variables ¶
View Source
var ErrBadWriter = errors.New("ErrBadWriter, it will be deleted from multiwriter")
Functions ¶
func DebugLog ¶
func DebugLog(args ...interface{})
DebugLog output formated(function and line calls) debug information
func DeleteWriters ¶ added in v1.0.12
func DeleteWriters(writerToDelete io.Writer, logFlags ...FgLogWriter)
DeleteWriters deletes mentioned writer from writers for mentioned logFlag
func ErrorLog ¶
func ErrorLog(err error, args ...interface{})
ErrorLog - output formatted (function and line calls) error information
func ErrorLogHandler ¶
func ErrorLogHandler(err error, args ...interface{})
ErrorLogHandler - output formatted(function and line calls) error information
func ErrorStack ¶
func ErrorStack(err error, args ...interface{})
ErrorStack - output formatted (function and line calls) error runtime stack information
func Fatal ¶
func Fatal(err error, args ...interface{})
Fatal - output formated (function and line calls) fatal information
func MultiWriter ¶ added in v1.0.12
creates a multiwriter
func NewWrapKitLogger ¶
func NewlogMess ¶
func NewlogMess(mess string, logger *wrapKitLogger) *logMess
func SetStackBeginWith ¶
SetStackBeginWith set stackBeginWith level for log, return old value
Types ¶
type LogsType ¶
type LogsType interface {
PrintToLogs() string
}
LogsType - interface for print logs record
type MultiwriterErr ¶ added in v1.0.22
type MultiwriterErr struct {
ErrorsList []WriterErr
}
func (MultiwriterErr) Error ¶ added in v1.0.22
func (mwe MultiwriterErr) Error() string
func (MultiwriterErr) String ¶ added in v1.0.290
func (mwe MultiwriterErr) String() string
Click to show internal directories.
Click to hide internal directories.