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.
| 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. |
| 89 | type LineWriter struct { |
| 90 | lineBuf lineBuf |
| 91 | lineFn func([]byte) |
| 92 | } |
| 93 | |
| 94 | // NewLineWriter creates a new LineWriter with the given callback function. |
| 95 | func NewLineWriter(lineFn func([]byte)) *LineWriter { |
nothing calls this directly
no outgoing calls
no test coverage detected