MCPcopy
hub / github.com/docker/compose / NewLogConsumer

Function NewLogConsumer

cmd/formatter/logs.go:47–58  ·  cmd/formatter/logs.go::NewLogConsumer

NewLogConsumer creates a new LogConsumer

(ctx context.Context, stdout, stderr io.Writer, color, prefix, timestamp bool)

Source from the content-addressed store, hash-verified

45
46// NewLogConsumer creates a new LogConsumer
47func NewLogConsumer(ctx context.Context, stdout, stderr io.Writer, color, prefix, timestamp bool) api.LogConsumer {
48 return &logConsumer{
49 ctx: ctx,
50 presenters: sync.Map{},
51 width: 0,
52 stdout: stdout,
53 stderr: stderr,
54 color: color,
55 prefix: prefix,
56 timestamp: timestamp,
57 }
58}
59
60func (l *logConsumer) register(name string) *presenter {
61 var p *presenter

Callers 3

runLogsFunction · 0.92
runUpFunction · 0.92
runWatchFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected