Stringer constructs a field with the given key and the output of the value's String method. The Stringer's String method is called lazily.
(key string, val fmt.Stringer)
| 339 | // Stringer constructs a field with the given key and the output of the value's |
| 340 | // String method. The Stringer's String method is called lazily. |
| 341 | func Stringer(key string, val fmt.Stringer) Field { |
| 342 | return Field{Key: key, Type: zapcore.StringerType, Interface: val} |
| 343 | } |
| 344 | |
| 345 | // Time constructs a Field with the given key and value. The encoder |
| 346 | // controls how the time is serialized. |
no outgoing calls