MCPcopy
hub / github.com/rs/zerolog / AsLogObjectMarshalers

Function AsLogObjectMarshalers

globals_118.go:10–19  ·  view source on GitHub ↗
(objs []T)

Source from the content-addressed store, hash-verified

8)
9
10func AsLogObjectMarshalers[T LogObjectMarshaler](objs []T) []LogObjectMarshaler {
11 if objs == nil {
12 return nil
13 }
14 s := make([]LogObjectMarshaler, len(objs))
15 for i, v := range objs {
16 s[i] = v
17 }
18 return s
19}
20
21func AsStringers[T fmt.Stringer](objs []T) []fmt.Stringer {
22 if objs == nil {

Callers 1

ExampleEvent_ObjectsFunction · 0.92

Calls

no outgoing calls

Tested by 1

ExampleEvent_ObjectsFunction · 0.74