output

package
v0.0.0-...-96e2191 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Format

type Format string

Format represents the output format

const (
	FormatJSON   Format = "json"
	FormatJSONL  Format = "jsonl"
	FormatCSV    Format = "csv"
	FormatPretty Format = "pretty"
)

type Writer

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

Writer handles formatted output

func NewStdoutWriter

func NewStdoutWriter(format string) (*Writer, error)

NewStdoutWriter creates a writer for stdout

func NewWriter

func NewWriter(format string, w io.Writer) (*Writer, error)

NewWriter creates a new output writer

func (*Writer) Flush

func (w *Writer) Flush() error

Flush flushes any buffered data

func (*Writer) WriteBatch

func (w *Writer) WriteBatch(batch emit.Batch) error

WriteBatch writes a batch in the configured format

Jump to

Keyboard shortcuts

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