accesslog

package
v0.0.0-...-c42a961 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessWriter

type AccessWriter struct {
	// contains filtered or unexported fields
}

func (*AccessWriter) Entry

func (w *AccessWriter) Entry() Entry

Entry returns access log entry

func (*AccessWriter) Write

func (r *AccessWriter) Write(body []byte) (int, error)

func (*AccessWriter) WriteHeader

func (r *AccessWriter) WriteHeader(statusCode int)

type AccessWriterOptions

type AccessWriterOptions struct {
	IgnoreRequestBody  bool
	IgnoreResponseBody bool
}

type Entry

type Entry struct {
	Request  Request
	Response Response
}

Entry access log entry

type Request

type Request struct {
	Header http.Header
	Method string
	URL    string
	Body   string
}

Request entry

type Response

type Response struct {
	Headers    http.Header
	StatusCode int
	Body       string
}

Response entry

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL