Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ResponseMiddleware ¶
func ResponseMiddleware() gin.HandlerFunc
ResponseMiddleware return a gin.HandlerFunc. The code after next takes effect in the reverse order. So must register this middleware before use BodyWriter.
Types ¶
type BodyWriter ¶
type BodyWriter struct { gin.ResponseWriter Body *bytes.Buffer }
BodyWriter inherit the ResponseWriter of Gin and add the body field to expose the response
Click to show internal directories.
Click to hide internal directories.