MCPcopy
hub / github.com/docker/docker-agent / console

Function console

pkg/tools/codemode/console.go:8–29  ·  view source on GitHub ↗
(stdOut, stdErr io.Writer)

Source from the content-addressed store, hash-verified

6)
7
8func console(stdOut, stdErr io.Writer) map[string]func(args ...any) {
9 return map[string]func(args ...any){
10 "debug": func(args ...any) {
11 fmt.Fprintln(stdOut, args...)
12 },
13 "info": func(args ...any) {
14 fmt.Fprintln(stdOut, args...)
15 },
16 "log": func(args ...any) {
17 fmt.Fprintln(stdOut, args...)
18 },
19 "trace": func(args ...any) {
20 fmt.Fprintln(stdOut, args...)
21 },
22 "warn": func(args ...any) {
23 fmt.Fprintln(stdOut, args...)
24 },
25 "error": func(args ...any) {
26 fmt.Fprintln(stdErr, args...)
27 },
28 }
29}

Callers 7

runJavascriptMethod · 0.85
TestConsole_debugFunction · 0.85
TestConsole_infoFunction · 0.85
TestConsole_logFunction · 0.85
TestConsole_traceFunction · 0.85
TestConsole_warnFunction · 0.85
TestConsole_errorFunction · 0.85

Calls

no outgoing calls

Tested by 6

TestConsole_debugFunction · 0.68
TestConsole_infoFunction · 0.68
TestConsole_logFunction · 0.68
TestConsole_traceFunction · 0.68
TestConsole_warnFunction · 0.68
TestConsole_errorFunction · 0.68