Documentation ¶
Index ¶
- Variables
- func DumpSlice(n string, v interface{})
- func DumpVar(n string, v interface{})
- func Mbegin()
- func Mcritical(msg string)
- func Mcritical_e(err error)
- func Merror(msg string)
- func Merror_e(err error)
- func Minfo(msg string)
- func Mok(msg string)
- func Mprompt(msg string)
- func Mverbose(msg string)
- func Mverbose_e(err error)
- func Mwarning(msg string)
- func Mwarning_e(err error)
- func ProcBegin(msg string)
- func ProcEnd()
- func ProcFail()
- func Readline() string
- func TraceIn(n string)
- func TraceOut(n string)
Constants ¶
This section is empty.
Variables ¶
var VerboseEnable = false
VerboseEnable controls output of Mverbose, Mverbose_e, DumpVar, and DumpSlice. If false, those functions yield nothing.
Functions ¶
func DumpSlice ¶
func DumpSlice(n string, v interface{})
DumpSlice prints slice length and content via Mverbose. WARNING: Will panic if passed argument is not a slice, or otherwise doesn't have Len().
func Mbegin ¶
func Mbegin()
Mbegin just prints a bright cyan word "begin!" if VerboseEnable is true. Used when debugging command line flags.
func Mcritical ¶
func Mcritical(msg string)
Mcritical prints a message with a bright red [CRIT] tag.
func Mcritical_e ¶
func Mcritical_e(err error)
Mcritical_e prints an error message with a bright red [CRIT] tag.
func Mprompt ¶
func Mprompt(msg string)
Mprompt prints a message with a white [----] tag. Intended for use before Readline.
func Mverbose ¶
func Mverbose(msg string)
Mverbose prints a message with a purple [VERB] tag, but only if VerboseEnable is true.
func Mverbose_e ¶
func Mverbose_e(err error)
Mverbose_e prints an error message with a purple [VERB] tag, but only if VerboseEnable is true.
func Mwarning_e ¶
func Mwarning_e(err error)
Mwarning_e prints an error message with a yellow [WARN] tag.
func ProcBegin ¶
func ProcBegin(msg string)
ProcBegin prints a message on processing something without a newline. To indicate ending, use ProcEnd or ProcFail, or fmt.Printf("\r") for manual formatting.
func ProcEnd ¶
func ProcEnd()
ProcEnd overwrites the label produced by ProcBegin, indicating success.
func ProcFail ¶
func ProcFail()
ProcFail overwrites the label produced by ProcBegin, indicating failure. To provide error details, use fmt.Printf("\r"), then e.g. Merror("...").
func Readline ¶
func Readline() string
Readline prints a white [>>>>] tag, then reads a string from stdin.
Types ¶
This section is empty.