glog

package
v0.0.0-...-63a5211 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HR

func HR(log *slog.Logger, height uint64, round uint32) *slog.Logger

HR returns a copy of log that includes fields for the given height and round.

This is a convenient shorthand in many log calls where the height and round are pertinent details.

func HRE

func HRE(log *slog.Logger, height uint64, round uint32, e error) *slog.Logger

HR returns a copy of log that includes fields for the given height, round, and error.

This is a convenient shorthand in many log calls where the height, round, and error are pertinent details.

Types

type Hex

type Hex []byte

Hex wraps a byte slice to ensure it serializes as a hex-encoded string. Without this, it gets rendered as a Unicode string with embedded escape codes.

func (Hex) LogValue

func (v Hex) LogValue() slog.Value

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL