MCPcopy Index your code
hub / github.com/wavetermdev/waveterm / LineWriter

Struct LineWriter

tsunami/util/streamtolines.go:89–92  ·  view source on GitHub ↗

LineWriter is an io.Writer that processes data line-by-line via a callback. Lines do not include the trailing newline. Lines longer than maxLineLength are dropped.

Source from the content-addressed store, hash-verified

87// LineWriter is an io.Writer that processes data line-by-line via a callback.
88// Lines do not include the trailing newline. Lines longer than maxLineLength are dropped.
89type LineWriter struct {
90 lineBuf lineBuf
91 lineFn func([]byte)
92}
93
94// NewLineWriter creates a new LineWriter with the given callback function.
95func NewLineWriter(lineFn func([]byte)) *LineWriter {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected