1
0
mirror of https://github.com/labstack/echo.git synced 2025-07-13 01:30:31 +02:00

Godoc updated

Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
Vishal Rana
2016-03-11 08:47:23 -08:00
parent 562173f89d
commit 237070a674
3 changed files with 5 additions and 1 deletions

View File

@ -68,13 +68,17 @@ type (
WriteTimeout time.Duration
}
// Handler defines an interface to server HTTP requests via `ServeHTTP(Request, Response)`
// function.
Handler interface {
ServeHTTP(Request, Response)
}
// HandlerFunc is an adapter to allow the use of `func(Request, Response)` as HTTP handlers.
HandlerFunc func(Request, Response)
)
// ServeHTTP serves HTTP request.
func (h HandlerFunc) ServeHTTP(req Request, res Response) {
h(req, res)
}