output

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2026 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Writer

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

Writer synchronises all output. Results go to stdout (and optionally a file); everything else (progress, verbose, errors) goes to stderr.

func New

func New(outWriter *bufio.Writer, simulate bool) *Writer

New returns a Writer. If outWriter is non-nil, resolved domains are also written there. Set simulate to true to tag result lines as simulated.

func (*Writer) Error

func (w *Writer) Error(format string, a ...any)

Error writes an error line to stderr.

func (*Writer) Info

func (w *Writer) Info(format string, a ...any)

Info writes an informational line to stderr.

func (*Writer) Progress

func (w *Writer) Progress(pct float64, processed, total, found int64)

Progress writes a progress line to stderr using carriage-return overwrite.

func (*Writer) ProgressDone

func (w *Writer) ProgressDone()

ProgressDone writes the final newline on stderr after progress reporting ends.

func (*Writer) Result

func (w *Writer) Result(domain string)

Result prints a resolved domain to stdout (and the output file if configured).

Jump to

Keyboard shortcuts

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