Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var LoggerDefaultDateFormat = time.RFC3339
LoggerDefaultDateFormat is the format used for date by the default Logger instance.
View Source
var LoggerDefaultFormat = "{{.Status}} | {{.Duration}} | {{.Hostname}} | {{.Method}} {{.Path}}"
LoggerDefaultFormat is the format logged used by the default Logger instance.
Functions ¶
This section is empty.
Types ¶
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger is a middleware handler that logs the request as it goes in and the response as it goes out.
func (*Logger) SetDateFormat ¶
SetDateFormat 设置日志的时间格式
Click to show internal directories.
Click to hide internal directories.