format

package
v0.13.8 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Formatter

type Formatter interface {
	// Format formats build list into string.
	Format(slice interface{}, fieldsToPrint ...string) string
}

Formatter formats slice into string.

func NewJSONFormatter

func NewJSONFormatter() Formatter

NewJSONFormatter returns formatter converting slice into json string.

func NewTableFormatter

func NewTableFormatter() Formatter

NewTableFormatter returns formatter converting slice into table string.

func Resolve

func Resolve(c *ioc.Container, config config.Format) Formatter

Resolve resolves concrete formatter based on config.

Jump to

Keyboard shortcuts

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