import "golang.org/x/build/livelog"
Package livelog provides a buffer that can be simultaneously written to by one writer and read from by many readers.
const MaxBufferSize = 2 << 20 // 2MB of output is way more than we expect.
type Buffer struct {
// contains filtered or unexported fields
}
Buffer is a WriteCloser that provides multiple Readers that each yield the same data. It is safe to Write to a Buffer while Readers consume that data. Its zero value is a ready-to-use buffer.
Bytes returns a copy of the underlying buffer.
Close signals EOF to all Readers.
func (b *Buffer) Reader() io.ReadCloser
Reader initializes and returns a ReadCloser that will emit the entire buffer. It is safe to call Read and Close concurrently.
String returns a copy of the underlying buffer as a string.
Write appends data to the Buffer. It will wake any blocked Readers.
Package livelog imports 2 packages (graph) and is imported by 1 packages. Updated 27 days ago. Refresh now. Tools for package owners.