logfmt

package
v0.8.1 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package logfmt provides utilities for writing key/value pairs in logfmt format.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WriteKeyValue

func WriteKeyValue(buf Writer, key, value interface{})

WriteKeyValue writes a key/value pair to the writer.

func WriteValue

func WriteValue(buf Writer, value interface{})

WriteValue writes the value to the writer.

Types

type Writer

type Writer interface {
	Write(p []byte) (n int, err error)
	WriteString(s string) (n int, err error)
	WriteRune(r rune) (n int, err error)
}

Writer is an interface implemented by both bytes.Buffer and strings.Builder

Jump to

Keyboard shortcuts

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