Help us shape the future of Go! Take the 2026 Go Developer Survey

printer

package
v0.46.0 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Printer

type Printer struct {
	// contains filtered or unexported fields
}

func New

func New(out io.Writer) *Printer

New returns new object of Printer

func (*Printer) JSON

func (p *Printer) JSON(data []byte, err error) error

JSON prints formats json data and prints it

func (*Printer) Raw

func (p *Printer) Raw(data []byte, err error) error

Raw prints the raw byte array to printer's output stream

func (*Printer) String

func (p *Printer) String(str string) error

String prints the string to printer's output stream

func (*Printer) Tabbed

func (p *Printer) Tabbed(tmpl *template.Template, templateData interface{}) error

Tabbed prints data in table form based on the template passed

Jump to

Keyboard shortcuts

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