MCPcopy Create free account
hub / github.com/prometheus/common / init

Function init

expfmt/encode.go:33–49  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

31var formatToAccept = map[Format]goautoneg.Accept{}
32
33func init() {
34 for _, f := range []Format{
35 FmtText,
36 FmtText_1_0_0,
37 FmtProtoDelim,
38 FmtProtoText,
39 FmtProtoCompact,
40 FmtOpenMetrics_1_0_0,
41 FmtOpenMetrics_2_0_0_rc,
42 FmtOpenMetrics_2_0_0,
43 FmtOpenMetrics_0_0_1,
44 } {
45 if parsed := goautoneg.ParseAccept(string(f)); len(parsed) > 0 {
46 formatToAccept[f] = parsed[0]
47 }
48 }
49}
50
51var (
52 defaultAcceptedFormats = []Format{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected