istio: Index | Files

package clog

import ""


Package Files


type ConsoleLogger Uses

type ConsoleLogger struct {
    // contains filtered or unexported fields

ConsoleLogger is the struct used for mesh command

func NewConsoleLogger Uses

func NewConsoleLogger(stdOut, stdErr io.Writer, scope *log.Scope) *ConsoleLogger

NewConsoleLogger creates a new logger and returns a pointer to it. stdOut and stdErr can be used to capture output for testing. If scope is nil, the default scope is used.

func NewDefaultLogger Uses

func NewDefaultLogger() *ConsoleLogger

NewDefaultLogger creates a new logger that outputs to stdout/stderr at default scope.

func (*ConsoleLogger) LogAndError Uses

func (l *ConsoleLogger) LogAndError(v ...interface{})

func (*ConsoleLogger) LogAndErrorf Uses

func (l *ConsoleLogger) LogAndErrorf(format string, a ...interface{})

func (*ConsoleLogger) LogAndFatal Uses

func (l *ConsoleLogger) LogAndFatal(a ...interface{})

func (*ConsoleLogger) LogAndFatalf Uses

func (l *ConsoleLogger) LogAndFatalf(format string, a ...interface{})

func (*ConsoleLogger) LogAndPrint Uses

func (l *ConsoleLogger) LogAndPrint(v ...interface{})

func (*ConsoleLogger) LogAndPrintf Uses

func (l *ConsoleLogger) LogAndPrintf(format string, a ...interface{})

func (*ConsoleLogger) Print Uses

func (l *ConsoleLogger) Print(s string)

func (*ConsoleLogger) PrintErr Uses

func (l *ConsoleLogger) PrintErr(s string)

type Logger Uses

type Logger interface {
    LogAndPrint(v ...interface{})
    LogAndError(v ...interface{})
    LogAndFatal(a ...interface{})
    LogAndPrintf(format string, a ...interface{})
    LogAndErrorf(format string, a ...interface{})
    LogAndFatalf(format string, a ...interface{})
    Print(s string)
    PrintErr(s string)

Logger provides optional log taps for console and test buffer outputs.

Package clog imports 4 packages (graph) and is imported by 7 packages. Updated 2020-12-19. Refresh now. Tools for package owners.