Documentation ¶
Index ¶
- Variables
- func SetFileRoot(root string) error
- type Request
- func (r *Request) AddFile(name, file string) *Request
- func (r *Request) AddHeader(name, value string) *Request
- func (r *Request) DelHeader(name string) *Request
- func (r *Request) Delete(data interface{}) *Response
- func (r *Request) Get() *Response
- func (r *Request) GetHeader(name string) string
- func (r *Request) HasHeader(name string) bool
- func (r *Request) Head(data interface{}) *Response
- func (r *Request) Patch(data interface{}) *Response
- func (r *Request) Post(data interface{}) *Response
- func (r *Request) Put(data interface{}) *Response
- func (r *Request) Send(method string, data interface{}) *Response
- func (r *Request) SetHeader(name string, value string) *Request
- func (r *Request) Upload(file string, chunksize int) *Response
- func (r *Request) WithHeader(headers http.Header) *Request
- func (r *Request) WithQuery(values neturl.Values) *Request
- type Response
Constants ¶
This section is empty.
Variables ¶
View Source
var HTTPHandlers = map[string]process.Handler{
"get": processHTTPGet,
"post": processHTTPPost,
"put": processHTTPPut,
"patch": processHTTPPatch,
"delete": processHTTPDelete,
"head": processHTTPHead,
"send": processHTTPSend,
}
HTTPHandlers the http handlers
Functions ¶
Types ¶
type Request ¶
type Request struct {
// contains filtered or unexported fields
}
Request HTTP Request
func (*Request) WithHeader ¶
WithHeader set the request headers
Click to show internal directories.
Click to hide internal directories.