Documentation
¶
Overview ¶
Package presenter provides terminal output formatting utilities.
Index ¶
- type Presenter
- func (p *Presenter) Error(format string, args ...interface{})
- func (p *Presenter) FormatDuration(d time.Duration) string
- func (p *Presenter) FormatTime(t time.Time) string
- func (p *Presenter) Info(format string, args ...interface{})
- func (p *Presenter) KeyValue(key string, value interface{})
- func (p *Presenter) NewTable(headers []string) *tablewriter.Table
- func (p *Presenter) Newline()
- func (p *Presenter) Print(format string, args ...interface{})
- func (p *Presenter) Println(args ...interface{})
- func (p *Presenter) StatusColor(status string) string
- func (p *Presenter) Success(format string, args ...interface{})
- func (p *Presenter) Title(title string)
- func (p *Presenter) Warning(format string, args ...interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Presenter ¶
type Presenter struct {
// contains filtered or unexported fields
}
Presenter handles terminal output formatting.
func (*Presenter) FormatDuration ¶
FormatDuration formats a duration for display.
func (*Presenter) FormatTime ¶
FormatTime formats a time for display.
func (*Presenter) NewTable ¶
func (p *Presenter) NewTable(headers []string) *tablewriter.Table
NewTable creates a new table writer.
func (*Presenter) StatusColor ¶
StatusColor returns a colored status string.
Click to show internal directories.
Click to hide internal directories.