Documentation
¶
Index ¶
Constants ¶
View Source
const ( LEVEL_0 = iota LEVEL_1 LEVEL_2 LEVEL_3 )
Each level has 2 spaces for PrefixWriter
Variables ¶
This section is empty.
Functions ¶
func PrintAnnotationsMultiline ¶
func PrintAnnotationsMultiline(level int, title, indent string, annotations map[string]string, w PrefixWriter)
outputAnnotationsMultilineWithIndent prints multiple annotations with a user-defined alignment. If annotation string is too long, we omit chars more than 140 length.
func PrintLabelsMultiline ¶
func PrintLabelsMultiline(level int, title, indent string, labels map[string]string, w PrefixWriter)
printLabelsMultiline prints multiple labels with a user-defined alignment.
Types ¶
type PrefixWriter ¶
type PrefixWriter interface { // Write writes text with the specified indentation level. Write(level int, format string, a ...interface{}) // WriteLine writes an entire line with no indentation level. WriteLine(a ...interface{}) // Flush forces indentation to be reset. Flush() }
PrefixWriter can write text at various indentation levels.
func NewPrefixWriter ¶
func NewPrefixWriter() PrefixWriter
NewPrefixWriter creates a new PrefixWriter.
Click to show internal directories.
Click to hide internal directories.