Documentation ¶
Index ¶
- type ColorPrinter
- type Printer
- func (p *Printer) FailureBgPrint(format string, a ...interface{}) string
- func (p *Printer) FailurePrint(format string, a ...interface{}) string
- func (p *Printer) HighlightPrint(format string, a ...interface{}) string
- func (p *Printer) Print(content string, times int)
- func (p *Printer) SuccessBgPrint(format string, a ...interface{}) string
- func (p *Printer) SuccessPrint(format string, a ...interface{}) string
- func (p *Printer) WarningBgPrint(format string, a ...interface{}) string
- func (p *Printer) WarningPrint(format string, a ...interface{}) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ColorPrinter ¶
type ColorPrinter struct { Success *color.Color SuccessBg *color.Color Warning *color.Color WarningBg *color.Color Failure *color.Color FailureBg *color.Color Highlight *color.Color Faint *color.Color }
ColorPrinter 颜色输出
type Printer ¶
type Printer struct { Writer io.Writer Colors ColorPrinter }
Printer 输出器
func (*Printer) FailureBgPrint ¶
FailureBgPrint 带有背景色的失败输出
func (*Printer) FailurePrint ¶
FailurePrint 失败的输出
func (*Printer) HighlightPrint ¶
HighlightPrint 高亮输出
func (*Printer) SuccessBgPrint ¶
SuccessBgPrint 带有背景色的输出
func (*Printer) SuccessPrint ¶
SuccessPrint 成功输出
func (*Printer) WarningBgPrint ¶
WarningBgPrint 带有背景的警告输出
func (*Printer) WarningPrint ¶
WarningPrint 警告输出
Click to show internal directories.
Click to hide internal directories.