v.io: v.io/x/ref/internal/logger Index | Files

package logger

import "v.io/x/ref/internal/logger"

Package logger provides access to an implementation of v23/logger.Logging for use within a runtime implementation. There is pre-created "global" logger and the ability to create new loggers.

Index

Package Files

logger.go

func IsAlreadyConfiguredError Uses

func IsAlreadyConfiguredError(err error) bool

IsAlreadyConfiguredError returns true if the err parameter indicates the the logger has already been configured.

type ManagedLogger Uses

type ManagedLogger interface {
    // Implement logging.Logging without referring to it.
    Info(args ...interface{})
    Infof(format string, args ...interface{})
    InfoDepth(depth int, args ...interface{})
    InfoStack(all bool)
    Error(args ...interface{})
    ErrorDepth(depth int, args ...interface{})
    Errorf(format string, args ...interface{})
    Fatal(args ...interface{})
    FatalDepth(depth int, args ...interface{})
    Fatalf(format string, args ...interface{})
    Panic(args ...interface{})
    PanicDepth(depth int, args ...interface{})
    Panicf(format string, args ...interface{})
    V(level int) bool
    VDepth(depth int, level int) bool
    VI(level int) interface {
        Info(args ...interface{})
        Infof(format string, args ...interface{})
        InfoDepth(depth int, args ...interface{})
        InfoStack(all bool)
    }
    VIDepth(depth int, level int) interface {
        Info(args ...interface{})
        Infof(format string, args ...interface{})
        InfoDepth(depth int, args ...interface{})
        InfoStack(all bool)
    }
    FlushLog()

    // Implement x/ref/internal.ManagedLog without referring to it.
    LogDir() string
    Stats() (Info, Error struct{ Lines, Bytes int64 })
    ConfigureFromFlags(opts ...vlog.LoggingOpts) error
    ConfigureFromArgs(opts ...vlog.LoggingOpts) error
    ExplicitlySetFlags() map[string]string
}

func Global Uses

func Global() ManagedLogger

Global returns the global logger.

func NewLogger Uses

func NewLogger(name string) ManagedLogger

NewLogger creates a new logger with the supplied name.

Package logger imports 1 packages (graph) and is imported by 58 packages. Updated 2020-10-22. Refresh now. Tools for package owners.