Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UpperSnake ¶
Types ¶
type HeaderFormatter ¶
type RowDataProvider ¶ added in v0.2.2
type RowDataProvider interface {
ProvideRowData() map[string]interface{}
}
type RowModifier ¶ added in v0.2.0
func WithAdditionalFields ¶ added in v0.2.0
func WithAdditionalFields(fields map[string]interface{}) RowModifier
type Table ¶
type Table struct {
// contains filtered or unexported fields
}
func NewTable ¶
func NewTable(opts ...TableOption) (*Table, error)
func (*Table) Write ¶
func (t *Table) Write(r RowDataProvider, mods ...RowModifier) error
type TableConfig ¶
type TableConfig struct { Out io.Writer Columns []string HFormatter HeaderFormatter NoColor bool NoHeaders bool PagerBin string }
func (*TableConfig) Default ¶
func (c *TableConfig) Default()
func (*TableConfig) Option ¶
func (c *TableConfig) Option(opts ...TableOption)
type TableOption ¶
type TableOption interface {
ConfigureTable(*TableConfig)
}
type WithColumns ¶
type WithColumns string
func (WithColumns) ConfigureTable ¶ added in v0.2.2
func (wc WithColumns) ConfigureTable(c *TableConfig)
type WithHeaderFormatter ¶
type WithHeaderFormatter HeaderFormatter
func (WithHeaderFormatter) ConfigureTable ¶ added in v0.2.2
func (wh WithHeaderFormatter) ConfigureTable(c *TableConfig)
type WithNoColor ¶ added in v0.2.2
type WithNoColor bool
func (WithNoColor) ConfigureTable ¶ added in v0.2.2
func (wn WithNoColor) ConfigureTable(c *TableConfig)
type WithNoHeaders ¶
type WithNoHeaders bool
func (WithNoHeaders) ConfigureTable ¶ added in v0.2.2
func (wn WithNoHeaders) ConfigureTable(c *TableConfig)
type WithOutput ¶
type WithOutput struct {
// contains filtered or unexported fields
}
func (WithOutput) ConfigureTable ¶ added in v0.2.2
func (wo WithOutput) ConfigureTable(c *TableConfig)
type WithPager ¶
type WithPager string
func (WithPager) ConfigureTable ¶ added in v0.2.2
func (wp WithPager) ConfigureTable(c *TableConfig)
Click to show internal directories.
Click to hide internal directories.