Documentation ¶
Index ¶
- func CacheExpires(r *http.Response) time.Time
- func CallAPI(cfg Configuration, request *http.Request) (*http.Response, error)
- func Decode(v interface{}, b []byte, contentType string) (err error)
- func MultipartDecode(b []byte, v interface{}, boundary string) (err error)
- func MultipartEncode(v interface{}, body *bytes.Buffer) (string, error)
- func ParameterToString(obj interface{}, collectionFormat string) string
- func PrepareRequest(ctx context.Context, cfg Configuration, path string, method string, ...) (localVarRequest *http.Request, err error)
- func ReportError(format string, a ...interface{}) error
- func SelectHeaderAccept(accepts []string) string
- func TypeCheckParameter(obj interface{}, expected string, name string) error
- type Configuration
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CacheExpires ¶
CacheExpires helper function to determine remaining time before repeating a request.
func MultipartDecode ¶
func ParameterToString ¶
ParameterToString convert interface{} parameters to string, using a delimiter if format is provided.
func PrepareRequest ¶
func PrepareRequest( ctx context.Context, cfg Configuration, path string, method string, postBody interface{}, headerParams map[string]string, queryParams url.Values, formParams url.Values, formFileName string, fileName string, fileBytes []byte) (localVarRequest *http.Request, err error)
prepareRequest build the request
func ReportError ¶
Prevent trying to import "fmt"
func SelectHeaderAccept ¶
SelectHeaderAccept join all accept types and return
func TypeCheckParameter ¶
Verify optional parameters are of the correct type.
Types ¶
Click to show internal directories.
Click to hide internal directories.