Documentation
¶
Overview ¶
Package redlogger implements a concurrent logging system.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrHandling errorHandling // = continueOnError
Functions ¶
Types ¶
type ErrorHandling ¶
type ErrorHandling interface {
String() string
Set()
}
ErrorHandling wraps error handling behavior.
type LogWriter ¶
type LogWriter struct {
// bufio.Writer // is a StringWriter
MultiWriter
}
type MultiWriter ¶
func NewMultiWriter ¶
func NewMultiWriter(writers ...io.Writer) MultiWriter
NewMultiWriter returns a MultiWriter that duplicates its writes to all the provided writers, similar to the Unix tee(1) command.
Write(p []byte) (n int, err error) // for bytes
MultiWriter implements the StringWriter interface:
WriteString(string) (int, error) // for strings
Each write is written to each listed writer, one at a time. If a listed writer returns an error, that overall write operation stops and returns the error; it does not continue down the list.
======================================================
Reference: go version go1.15.6 src/io/multi.go
Copyright 2010 The Go Authors. All rights reserved. Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.