session

package
v0.0.0-...-8b129d1 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2017 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrPostTimeOut       = errors.New("post request timeout")
	ErrBenchmarkerCancel = errors.New("Benchmarker Cancelled")
)

Functions

This section is empty.

Types

type Session

type Session struct {
	Host      string
	Client    *http.Client
	Transport *http.Transport
	Cookies   []*http.Cookie
	Cache     *cache.Cache
	Storage   map[string]interface{}
	// contains filtered or unexported fields
}

func NewSession

func NewSession(ctx context.Context, host string) *Session

func (*Session) Close

func (s *Session) Close()

func (*Session) SendFormPost

func (s *Session) SendFormPost(uri string, body map[string]string) (*http.Response, error)

func (*Session) SendSimpleRequest

func (s *Session) SendSimpleRequest(method, uri string, body io.Reader) (*http.Response, error)

Jump to

Keyboard shortcuts

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