Documentation ¶
Index ¶
- type BaseTemplate
- type ClientConfig
- type RestTemplate
- func (rest *RestTemplate) DeleteForObject(url string, response interface{}, uriVariables ...string) error
- func (rest *RestTemplate) Execute(url, method string, header http.Header, body, response interface{}, ...) error
- func (rest *RestTemplate) ExecuteForJsonString(url, method string, header http.Header, body string, response interface{}, ...) error
- func (rest *RestTemplate) ExecuteForObject(url, method string, header http.Header, body, response interface{}, ...) error
- func (rest *RestTemplate) GetForObject(url string, response interface{}, uriVariables ...string) error
- func (rest *RestTemplate) HeadForObject(url string, header http.Header, response interface{}, uriVariables ...string) error
- func (rest *RestTemplate) PostForObject(url string, body, response interface{}, uriVariables ...string) error
- func (rest *RestTemplate) PutForObject(url string, body, response interface{}, uriVariables ...string) error
- type Template
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseTemplate ¶
type BaseTemplate interface { GetForObject(url string, response interface{}, uriVariables ...string) error PostForObject(url string, body, response interface{}, uriVariables ...string) error PutForObject(url string, body, response interface{}, uriVariables ...string) error DeleteForObject(url string, response interface{}, uriVariables ...string) HeadForObject(url string, header http.Header, response interface{}, uriVariables ...string) error ExecuteForJsonString(url, method string, header http.Header, body string, response interface{}, uriVariables ...string) error ExecuteForObject(url, method string, header http.Header, body, response interface{}, uriVariables ...string) error Execute(url, method string, header http.Header, body, response interface{}, uriVariables ...string) error }
type ClientConfig ¶
type RestTemplate ¶
type RestTemplate struct { Template ClientConfig *ClientConfig }
func Config ¶
func Config(cfg ClientConfig) *RestTemplate
func Default ¶
func Default() *RestTemplate
func DefaultProxy ¶
func DefaultProxy(proxy string) *RestTemplate
func (*RestTemplate) DeleteForObject ¶
func (rest *RestTemplate) DeleteForObject(url string, response interface{}, uriVariables ...string) error
func (*RestTemplate) ExecuteForJsonString ¶
func (*RestTemplate) ExecuteForObject ¶
func (*RestTemplate) GetForObject ¶
func (rest *RestTemplate) GetForObject(url string, response interface{}, uriVariables ...string) error
func (*RestTemplate) HeadForObject ¶
func (*RestTemplate) PostForObject ¶
func (rest *RestTemplate) PostForObject(url string, body, response interface{}, uriVariables ...string) error
func (*RestTemplate) PutForObject ¶
func (rest *RestTemplate) PutForObject(url string, body, response interface{}, uriVariables ...string) error
Click to show internal directories.
Click to hide internal directories.