logger

package
v0.0.0-...-2668204 Latest Latest
Warning

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

Go to latest
Published: May 4, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LogWriter

type LogWriter struct {
	// contains filtered or unexported fields
}

func NewLogWriter

func NewLogWriter(logger log.Logger) *LogWriter

NewLogWriter creates a new log writer that writes messages of a subprocess to the provided logger.

func NewLogWriterWithLevel

func NewLogWriterWithLevel(logger log.Logger, level slog.Level) *LogWriter

func (*LogWriter) Close

func (lw *LogWriter) Close() error

func (*LogWriter) Write

func (lw *LogWriter) Write(p []byte) (n int, err error)

Write writes data to the logger. It will split the data into lines and write each line separately.

type MultiWriterCloser

type MultiWriterCloser struct {
	io.Writer
	// contains filtered or unexported fields
}

func NewMultiWriterCloser

func NewMultiWriterCloser(writerClosers ...io.WriteCloser) *MultiWriterCloser

func (*MultiWriterCloser) Close

func (m *MultiWriterCloser) Close() error

Close closes all the underlying io.WriteCloser instances and returns the first error if any. If all close calls succeed, it returns nil.

Jump to

Keyboard shortcuts

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