client

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2019 License: MIT Imports: 7 Imported by: 6

Documentation

Index

Constants

View Source
const AGENT = "gdc-client/%s (%s %s) %s (%s)"
View Source
const RESOURCE = "https://%s:%d%s"

Variables

View Source
var Version = "dev"

NOTE This variable will be replaced at travis build time with the tag currently pointing to HEAD in the git repo. See the .travis-ci.yml for specifics on how it is built.

Functions

This section is empty.

Types

type Client

type Client struct {
	http.Client
	// contains filtered or unexported fields
}

func NewClient

func NewClient(host string, port uint16) *Client

func (*Client) Delete

func (c *Client) Delete(path string, token string) (*http.Response, error)

func (*Client) Do

func (c *Client) Do(req *http.Request) (*http.Response, error)

func (*Client) Get

func (c *Client) Get(path string, token string) (*http.Response, error)

func (*Client) Head

func (c *Client) Head(path string, token string) (*http.Response, error)

func (*Client) Post

func (c *Client) Post(path string, token string, body io.Reader) (*http.Response, error)

func (*Client) Put

func (c *Client) Put(path string, token string, body io.Reader) (*http.Response, error)

func (*Client) Request

func (c *Client) Request(verb string, path string, token string, body io.Reader) (*http.Request, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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