request

package
v2.1.1+incompatible Latest Latest
Warning

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

Go to latest
Published: May 22, 2018 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Version = "1.0"

Functions

This section is empty.

Types

type Request

type Request interface {
	SetHeader(string, ...string) Request
	Headers() map[string][]string
	SetQueryParam(string, ...string) Request
	QueryParams() map[string][]string
	UrlPath() string
	SetJSON(string) Request
	SetRawBody([]byte) Request

	SetFormParam(string, ...string) Request
	FormParams() map[string][]string

	AddFile(string, string, []byte) Request

	Send() (Response, error)
}

func Method

func Method(method string, urlPath string) (Request, error)

type Response

type Response interface {
	StatusCode() int
	Headers() map[string][]string
	Protocol() string
	Body() []byte
	ContentLength() int64
}

Jump to

Keyboard shortcuts

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