mock

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HostNotExist = "host not exist"
)

Variables

This section is empty.

Functions

func HostNotExistError

func HostNotExistError(host string) error

Types

type ClientBuilder

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

func NewClientBuilder

func NewClientBuilder() *ClientBuilder

func (*ClientBuilder) Build

func (builder *ClientBuilder) Build() gotten.Client

func (*ClientBuilder) Register

func (builder *ClientBuilder) Register(base string, handler http.Handler)

base: host or host:port

func (*ClientBuilder) RegisterFunc

func (builder *ClientBuilder) RegisterFunc(base string, handler http.HandlerFunc)

type ClientImpl

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

func (ClientImpl) Do

func (client ClientImpl) Do(req *http.Request) (resp *http.Response, err error)

Jump to

Keyboard shortcuts

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