Documentation ¶
Index ¶
- func DeleteRequest(ctx context.Context, returnValuePointer interface{}, baseUrl string, ...) errors.EdgeX
- func FromContext(ctx context.Context, key string) string
- func GetRequest(ctx context.Context, returnValuePointer interface{}, baseUrl string, ...) errors.EdgeX
- func GetRequestAndReturnBinaryRes(ctx context.Context, baseUrl string, requestPath string, ...) (res []byte, contentType string, edgeXerr errors.EdgeX)
- func GetRequestWithBodyRawData(ctx context.Context, returnValuePointer interface{}, baseUrl string, ...) errors.EdgeX
- func PatchRequest(ctx context.Context, returnValuePointer interface{}, url string, ...) errors.EdgeX
- func PostByFileRequest(ctx context.Context, returnValuePointer interface{}, url string, ...) errors.EdgeX
- func PostRequest(ctx context.Context, returnValuePointer interface{}, url string, data []byte, ...) errors.EdgeX
- func PostRequestWithRawData(ctx context.Context, returnValuePointer interface{}, url string, ...) errors.EdgeX
- func PutByFileRequest(ctx context.Context, returnValuePointer interface{}, url string, ...) errors.EdgeX
- func PutRequest(ctx context.Context, returnValuePointer interface{}, url string, ...) errors.EdgeX
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteRequest ¶
func DeleteRequest(ctx context.Context, returnValuePointer interface{}, baseUrl string, requestPath string) errors.EdgeX
DeleteRequest makes the delete request and return the body
func FromContext ¶
FromContext allows for the retrieval of the specified key's value from the supplied Context. If the value is not found, an empty string is returned.
func GetRequest ¶
func GetRequest(ctx context.Context, returnValuePointer interface{}, baseUrl string, requestPath string, requestParams url.Values) errors.EdgeX
GetRequest makes the get request and return the body
func GetRequestAndReturnBinaryRes ¶
func GetRequestAndReturnBinaryRes(ctx context.Context, baseUrl string, requestPath string, requestParams url.Values) (res []byte, contentType string, edgeXerr errors.EdgeX)
GetRequestAndReturnBinaryRes makes the get request and return the binary response and content type(i.e., application/json, application/cbor, ... )
func GetRequestWithBodyRawData ¶ added in v2.1.0
func GetRequestWithBodyRawData(ctx context.Context, returnValuePointer interface{}, baseUrl string, requestPath string, requestParams url.Values, data interface{}) errors.EdgeX
GetRequestWithBodyRawData makes the GET request with JSON raw data as request body and return the response
func PatchRequest ¶
func PatchRequest( ctx context.Context, returnValuePointer interface{}, url string, data interface{}) errors.EdgeX
PatchRequest makes a PATCH request and unmarshals the response to the returnValuePointer
func PostByFileRequest ¶
func PostByFileRequest( ctx context.Context, returnValuePointer interface{}, url string, filePath string) errors.EdgeX
PostByFileRequest makes the post file request and return the body
func PostRequest ¶
func PostRequest( ctx context.Context, returnValuePointer interface{}, url string, data []byte, encoding string) errors.EdgeX
PostRequest makes the post request with encoded data and return the body
func PostRequestWithRawData ¶
func PostRequestWithRawData( ctx context.Context, returnValuePointer interface{}, url string, data interface{}) errors.EdgeX
PostRequestWithRawData makes the post JSON request with raw data and return the body
Types ¶
This section is empty.