JSON is a Formatter type for JSON logs.
| 11 | |
| 12 | // JSON is a Formatter type for JSON logs. |
| 13 | type JSON struct { |
| 14 | // Indent in spaces. |
| 15 | // Note that, if set to > 0 then jsoniter is used instead of easyjson. |
| 16 | Indent string |
| 17 | EscapeHTML bool |
| 18 | HumanTime bool |
| 19 | |
| 20 | jsoniter jsoniter.API |
| 21 | ac *AccessLog |
| 22 | } |
| 23 | |
| 24 | // SetOutput creates the json encoder writes to the "dest". |
| 25 | // It's called automatically by the middleware when this Formatter is used. |
nothing calls this directly
no outgoing calls
no test coverage detected