Documentation ¶
Overview ¶
Package templateutil contains template functions from prometheus_bot
Index ¶
- Constants
- func HasKey(dict map[string]interface{}, keySearch string) bool
- func StrFormatByte(in string, j1 int) string
- func StrFormatDate(toformat string, templateTimeZone string, templateTimeOutFormat string) string
- func StrFormatFloat(f string) string
- func StrFormatInt(i string) string
- func StrFormatMeasureUnit(MeasureUnit string, value string, templateSplitToken string) string
- func StrFormatScale(in string, j1 int) string
Constants ¶
View Source
const ( Kb = iota Mb Gb Tb Pb Eb Zb Yb InformationSizeMAX )
*
- Subdivideb by 1024
View Source
const ( K = iota M G T P E Z Y ScaleSizeMAX )
*
- Subdivided by 10000
Variables ¶
This section is empty.
Functions ¶
func StrFormatByte ¶
StrFormatByte scales number for It measure unit
func StrFormatDate ¶
StrFormatDate formats as date
func StrFormatMeasureUnit ¶
StrFormatMeasureUnit formats the template
func StrFormatScale ¶
StrFormatScale formats number for fisics measure unit
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.