Documentation
¶
Index ¶
- func AtLevel(ctx context.Context, level logf.Level, fn func(logf.LogFunc))
- func Debug(ctx context.Context, text string, fs ...logf.Field)
- func Error(ctx context.Context, text string, fs ...logf.Field)
- func Get(ctx context.Context) *logf.Logger
- func Info(ctx context.Context, text string, fs ...logf.Field)
- func New(parent context.Context, logger *logf.Logger) context.Context
- func Warn(ctx context.Context, text string, fs ...logf.Field)
- func With(ctx context.Context, fields ...logf.Field) context.Context
- func WithCaller(ctx context.Context) context.Context
- func WithCallerSkip(ctx context.Context, n int) context.Context
- func WithGroup(ctx context.Context, name string) context.Context
- func WithName(ctx context.Context, name string) context.Context
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Get ¶
Get returns the logf.Logger associated with ctx. Returns DisabledLogger() if no logger is associated.
func With ¶
With returns a new context with the logger derived from ctx with the given additional fields.
func WithCaller ¶
WithCaller returns a new context with the logger derived from ctx with caller reporting enabled.
func WithCallerSkip ¶
WithCallerSkip returns a new context with the logger derived from ctx with increased number of skipped caller frames.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.