httpClient

package
v1.2.4 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RestClient

type RestClient struct {
	*http.Client
}

func New

func New() RestClient

func NewWithClient added in v1.2.4

func NewWithClient(client *http.Client) RestClient

func (RestClient) Delete

func (r RestClient) Delete(url string) (*http.Response, error)

func (RestClient) DeleteJson added in v1.1.0

func (r RestClient) DeleteJson(url string, body interface{}) (*http.Response, error)

func (RestClient) Get

func (r RestClient) Get(url string) (*http.Response, error)

func (RestClient) Post added in v1.1.0

func (r RestClient) Post(url string) (*http.Response, error)

func (RestClient) PostJson

func (r RestClient) PostJson(url string, body interface{}) (*http.Response, error)

func (RestClient) Put added in v1.1.0

func (r RestClient) Put(url string) (*http.Response, error)

func (RestClient) PutJson

func (r RestClient) PutJson(url string, body interface{}) (*http.Response, error)

func (RestClient) WithAuthentication added in v1.2.4

func (r RestClient) WithAuthentication(tokenSource oauth2.TokenSource) RestClient

func (RestClient) WithTimeout

func (r RestClient) WithTimeout(timeout time.Duration) RestClient

func (RestClient) WithTransport added in v1.2.4

func (r RestClient) WithTransport(tr http.RoundTripper) RestClient

Jump to

Keyboard shortcuts

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