output

package
v0.0.0-...-167d62f Latest Latest
Warning

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

Go to latest
Published: May 9, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Format

func Format(rows *DataTable) string

func FormatOutputPrettyTable

func FormatOutputPrettyTable(dataTable *DataTable) table.Writer

func IsPrettyTable

func IsPrettyTable() bool

func Prepare

func Prepare(rows *DataTable, msg string)

func PrettyTableAddKarma

func PrettyTableAddKarma(column int)

func PrettyTableHeaders

func PrettyTableHeaders(newHeaders []string)

func PrettyTableRelativeTimestamps

func PrettyTableRelativeTimestamps(column int)

func PrettyTableSortBy

func PrettyTableSortBy(columns ...string)

func PrintPrepared

func PrintPrepared()

Types

type DataTable

type DataTable struct {
	Headers []interface{}
	Rows    map[int]*TableRow
}

func NewDataTable

func NewDataTable(headers []interface{}) *DataTable

func (*DataTable) Append

func (dt *DataTable) Append(row *TableRow)

type TableRow

type TableRow = map[string]string

Jump to

Keyboard shortcuts

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