Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type JSONFormatter ¶
type JSONFormatter struct {
// contains filtered or unexported fields
}
JSONFormatter implements a log formatter that outputs JSON formatted logs.
func NewJSONFormatter ¶
func NewJSONFormatter(w io.Writer, prefix, indent string) *JSONFormatter
NewJSONFormatter creates a new JSONFormatter that writes to with the specified prefix and indent.
func (*JSONFormatter) Format ¶
func (js *JSONFormatter) Format(v any) error
Format formats the specified value as JSON.
Click to show internal directories.
Click to hide internal directories.