MCPcopy
hub / github.com/uber-go/zap / NewAtomicLevel

Function NewAtomicLevel

level.go:79–83  ·  level.go::NewAtomicLevel

NewAtomicLevel creates an AtomicLevel with InfoLevel and above logging enabled.

()

Source from the content-addressed store, hash-verified

77// NewAtomicLevel creates an AtomicLevel with InfoLevel and above logging
78// enabled.
79func NewAtomicLevel() AtomicLevel {
80 lvl := AtomicLevel{l: new(atomic.Int32)}
81 lvl.l.Store(int32(InfoLevel))
82 return lvl
83}
84
85// NewAtomicLevelAt is a convenience function that creates an AtomicLevel
86// and then calls SetLevel with the given level.

Callers 11

TestAtomicLevelServeHTTPFunction · 0.92
FuzzAtomicLevelServeHTTPFunction · 0.92
ExampleAtomicLevelFunction · 0.92
TestLoggerAtomicLevelFunction · 0.85
NewAtomicLevelAtFunction · 0.85
ParseAtomicLevelFunction · 0.85
TestNewAtomicLevelFunction · 0.85
TestParseAtomicLevelFunction · 0.85
TestAtomicLevelMutationFunction · 0.85

Calls

no outgoing calls

Tested by 9

TestAtomicLevelServeHTTPFunction · 0.74
FuzzAtomicLevelServeHTTPFunction · 0.74
ExampleAtomicLevelFunction · 0.74
TestLoggerAtomicLevelFunction · 0.68
TestNewAtomicLevelFunction · 0.68
TestParseAtomicLevelFunction · 0.68
TestAtomicLevelMutationFunction · 0.68