capture

package
v1.9.8 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2017 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Capture

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

func New

func New(c chan Response) *Capture

func (*Capture) NewWriteCloser

func (c *Capture) NewWriteCloser(res *http.Response) (io.WriteCloser, error)

type CaptureWriteCloser

type CaptureWriteCloser struct {
	bytes.Buffer
	// contains filtered or unexported fields
}

func (*CaptureWriteCloser) Close

func (cwc *CaptureWriteCloser) Close() error
type Header struct {
	http.Header
}

func (Header) MarshalDB

func (h Header) MarshalDB() (interface{}, error)

func (*Header) UnmarshalDB

func (h *Header) UnmarshalDB(data interface{}) error

type Response

type Response struct {
	ID            uint64    `json:"id" db:"id,omitempty"`
	Origin        string    `json:"origin" db:"origin"`
	Method        string    `json:"method" db:"method"`
	Status        int       `json:"status" db:"status"`
	ContentType   string    `json:"content_type" db:"content_type"`
	ContentLength uint64    `json:"content_length" db:"content_length"`
	Host          string    `json:"host" db:"host"`
	URL           string    `json:"url" db:"url"`
	Scheme        string    `json:"scheme" db:"scheme"`
	Path          string    `json:"path" db:"path"`
	Header        Header    `json:"header,omitempty" db:"header"`
	Body          []byte    `json:"body,omitempty" db:"body"`
	RequestHeader Header    `json:"request_header,omitempty" db:"request_header"`
	RequestBody   []byte    `json:"request_body,omitempty" db:"request_body"`
	DateStart     time.Time `json:"date_start" db:"date_start"`
	DateEnd       time.Time `json:"date_end" db:"date_end"`
	TimeTaken     int64     `json:"time_taken" db:"time_taken"`
}

Jump to

Keyboard shortcuts

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