Documentation ¶
Index ¶
Constants ¶
View Source
const CacheStatusHeader = "X-Go-Proxy-Cache-Status"
CacheStatusHeader - HTTP Header for showing cache status
View Source
const CacheStatusHeaderHit = "HIT"
CacheStatusHeaderHit - Cache status HIT for HTTP Header X-Go-Proxy-Cache-Status
View Source
const CacheStatusHeaderMiss = "MISS"
CacheStatusHeaderMiss - Cache status MISS for HTTP Header X-Go-Proxy-Cache-Status
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LoggedResponseWriter ¶
type LoggedResponseWriter struct { http.ResponseWriter StatusCode int Content [][]byte }
LoggedResponseWriter - Decorator for http.ResponseWriter
func NewLoggedResponseWriter ¶
func NewLoggedResponseWriter(w http.ResponseWriter) *LoggedResponseWriter
NewLoggedResponseWriter - Creates new instance of ResponseWriter.
func (*LoggedResponseWriter) CopyHeaders ¶
func (lwr *LoggedResponseWriter) CopyHeaders(src http.Header)
CopyHeaders - Adds the headers to the response.
func (*LoggedResponseWriter) Reset ¶
func (lwr *LoggedResponseWriter) Reset()
Reset - Reset the stored content of LoggedResponseWriter.
func (*LoggedResponseWriter) Write ¶
func (lwr *LoggedResponseWriter) Write(p []byte) (int, error)
Write - ResponseWriter's Write method decorator.
func (*LoggedResponseWriter) WriteBody ¶
func (lwr *LoggedResponseWriter) WriteBody(page string) bool
WriteBody - Sends the body to the client.
func (*LoggedResponseWriter) WriteHeader ¶
func (lwr *LoggedResponseWriter) WriteHeader(statusCode int)
WriteHeader - ResponseWriter's WriteHeader method decorator.
Click to show internal directories.
Click to hide internal directories.