Documentation ¶
Index ¶
- func AddJsonBodyTenantIDAndUserID(c *api.Context, tenantIDField string, userIDField string) error
- func AddQueryParamsTenantIDAndUserID(c *api.Context, tenantIDField string, userIDField string) error
- func DestroyGateway(gw *Gateway)
- type BodyFormFunc
- type Builder
- func (builder *Builder) Build(middlewares ...api.Handler)
- func (builder *Builder) Delete(request *DeleteRequest, requestCallbackFunc RequestResponseCallback) *Builder
- func (builder *Builder) Get(request *GetRequest, requestCallbackFunc RequestResponseCallback) *Builder
- func (builder *Builder) GlobalRequestCallback(globalRequestResponseCallback GlobalRequestResponseCallback) *Builder
- func (builder *Builder) Local(handler api.Handler, middlewares ...api.Handler)
- func (builder *Builder) Post(request *PostRequest, requestCallbackFunc RequestResponseCallback) *Builder
- func (builder *Builder) Put(request *PutRequest, requestCallbackFunc RequestResponseCallback) *Builder
- func (builder *Builder) ResponseErrorCallback(responseErrorCallback ResponseErrorCallback) *Builder
- func (builder *Builder) ResponseSuccessCallback(responseSuccessCallback ResponseSuccessCallback) *Builder
- func (builder *Builder) Url(httpMethod string, relativePath string) *Builder
- type BuilderRequest
- type DeleteRequest
- type DeleteRequestOption
- func DeleteRequestWithHeadersForm(headersFormFunc HeadersFormFunc) DeleteRequestOption
- func DeleteRequestWithPathParamsForm(pathParamsFormFunc PathParamsFormFunc) DeleteRequestOption
- func DeleteRequestWithQueryParamsForm(queryParamsFormFunc QueryParamsFormFunc) DeleteRequestOption
- func DeleteRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) DeleteRequestOption
- type DeleteRequestOptions
- type Gateway
- type GetRequest
- type GetRequestOption
- func GetRequestWithHeadersForm(headersFormFunc HeadersFormFunc) GetRequestOption
- func GetRequestWithPathParamsForm(pathParamsFormFunc PathParamsFormFunc) GetRequestOption
- func GetRequestWithQueryParamsForm(queryParamsFormFunc QueryParamsFormFunc) GetRequestOption
- func GetRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) GetRequestOption
- type GetRequestOptions
- type GlobalRequestResponseCallback
- type HeadersFormFunc
- type LocalServiceFunc
- type Option
- type Options
- type PathParamsFormFunc
- type PostRequest
- type PostRequestOption
- type PostRequestOptions
- type PutRequest
- type PutRequestOption
- type PutRequestOptions
- type QueryParamsFormFunc
- type RequestResponseCallback
- type ResponseErrorCallback
- type ResponseSuccessCallback
- type UrlTransferFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddJsonBodyTenantIDAndUserID ¶ added in v0.4.0
func AddQueryParamsTenantIDAndUserID ¶ added in v0.4.0
func DestroyGateway ¶
func DestroyGateway(gw *Gateway)
Types ¶
type BodyFormFunc ¶ added in v0.6.0
type BodyFormFunc func(c *api.Context, historyRequest []BuilderRequest, resultMap map[string]any) (any, error)
func FormJsonBodyWithTenantIDAndUserIDFunc ¶ added in v0.6.0
func FormJsonBodyWithTenantIDAndUserIDFunc(tenantIDFieldName string, userIDFieldName string) BodyFormFunc
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
func (*Builder) Delete ¶
func (builder *Builder) Delete(request *DeleteRequest, requestCallbackFunc RequestResponseCallback) *Builder
func (*Builder) Get ¶
func (builder *Builder) Get(request *GetRequest, requestCallbackFunc RequestResponseCallback) *Builder
func (*Builder) GlobalRequestCallback ¶ added in v0.4.0
func (builder *Builder) GlobalRequestCallback(globalRequestResponseCallback GlobalRequestResponseCallback) *Builder
func (*Builder) Post ¶
func (builder *Builder) Post(request *PostRequest, requestCallbackFunc RequestResponseCallback) *Builder
func (*Builder) Put ¶
func (builder *Builder) Put(request *PutRequest, requestCallbackFunc RequestResponseCallback) *Builder
func (*Builder) ResponseErrorCallback ¶ added in v0.4.0
func (builder *Builder) ResponseErrorCallback(responseErrorCallback ResponseErrorCallback) *Builder
func (*Builder) ResponseSuccessCallback ¶ added in v0.4.0
func (builder *Builder) ResponseSuccessCallback(responseSuccessCallback ResponseSuccessCallback) *Builder
type BuilderRequest ¶
type BuilderRequest interface { Request(c *api.Context, request *http_client.Request, historyRequest []BuilderRequest, resultMap map[string]any) (BuilderRequest, error) Response() *http_client.Response }
type DeleteRequest ¶
type DeleteRequest struct {
// contains filtered or unexported fields
}
func NewDeleteRequest ¶ added in v0.6.0
func NewDeleteRequest(url string, opts ...DeleteRequestOption) *DeleteRequest
func (*DeleteRequest) Request ¶
func (req *DeleteRequest) Request(c *api.Context, request *http_client.Request, historyRequest []BuilderRequest, resultMap map[string]any) (BuilderRequest, error)
func (*DeleteRequest) Response ¶
func (req *DeleteRequest) Response() *http_client.Response
type DeleteRequestOption ¶ added in v0.6.0
type DeleteRequestOption func(options *DeleteRequestOptions)
func DeleteRequestWithHeadersForm ¶ added in v0.6.0
func DeleteRequestWithHeadersForm(headersFormFunc HeadersFormFunc) DeleteRequestOption
func DeleteRequestWithPathParamsForm ¶ added in v0.6.0
func DeleteRequestWithPathParamsForm(pathParamsFormFunc PathParamsFormFunc) DeleteRequestOption
func DeleteRequestWithQueryParamsForm ¶ added in v0.6.0
func DeleteRequestWithQueryParamsForm(queryParamsFormFunc QueryParamsFormFunc) DeleteRequestOption
func DeleteRequestWithUrlTransferFunc ¶ added in v0.6.0
func DeleteRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) DeleteRequestOption
type DeleteRequestOptions ¶ added in v0.6.0
type DeleteRequestOptions struct {
// contains filtered or unexported fields
}
type GetRequest ¶
type GetRequest struct {
// contains filtered or unexported fields
}
func NewGetRequest ¶ added in v0.6.0
func NewGetRequest(url string, opts ...GetRequestOption) *GetRequest
func (*GetRequest) Request ¶
func (req *GetRequest) Request(c *api.Context, request *http_client.Request, historyRequest []BuilderRequest, resultMap map[string]any) (BuilderRequest, error)
func (*GetRequest) Response ¶
func (req *GetRequest) Response() *http_client.Response
type GetRequestOption ¶ added in v0.6.0
type GetRequestOption func(options *GetRequestOptions)
func GetRequestWithHeadersForm ¶ added in v0.6.0
func GetRequestWithHeadersForm(headersFormFunc HeadersFormFunc) GetRequestOption
func GetRequestWithPathParamsForm ¶ added in v0.6.0
func GetRequestWithPathParamsForm(pathParamsFormFunc PathParamsFormFunc) GetRequestOption
func GetRequestWithQueryParamsForm ¶ added in v0.6.0
func GetRequestWithQueryParamsForm(queryParamsFormFunc QueryParamsFormFunc) GetRequestOption
func GetRequestWithUrlTransferFunc ¶ added in v0.6.0
func GetRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) GetRequestOption
type GetRequestOptions ¶ added in v0.6.0
type GetRequestOptions struct {
// contains filtered or unexported fields
}
type GlobalRequestResponseCallback ¶ added in v0.4.0
type GlobalRequestResponseCallback func(c *api.Context, request BuilderRequest, historyRequests []BuilderRequest, resultMap map[string]any) error
type HeadersFormFunc ¶ added in v0.6.0
type LocalServiceFunc ¶ added in v0.6.0
type PathParamsFormFunc ¶ added in v0.6.0
type PostRequest ¶
type PostRequest struct {
// contains filtered or unexported fields
}
func NewPostRequest ¶ added in v0.6.0
func NewPostRequest(url string, opts ...PostRequestOption) *PostRequest
func (*PostRequest) Request ¶
func (req *PostRequest) Request(c *api.Context, request *http_client.Request, historyRequest []BuilderRequest, resultMap map[string]any) (BuilderRequest, error)
func (*PostRequest) Response ¶
func (req *PostRequest) Response() *http_client.Response
type PostRequestOption ¶ added in v0.6.0
type PostRequestOption func(options *PostRequestOptions)
func PostRequestWithBodyForm ¶ added in v0.6.0
func PostRequestWithBodyForm(bodyFormFunc BodyFormFunc) PostRequestOption
func PostRequestWithHeadersForm ¶ added in v0.6.0
func PostRequestWithHeadersForm(headersFormFunc HeadersFormFunc) PostRequestOption
func PostRequestWithUrlTransferFunc ¶ added in v0.6.0
func PostRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) PostRequestOption
type PostRequestOptions ¶ added in v0.6.0
type PostRequestOptions struct {
// contains filtered or unexported fields
}
type PutRequest ¶
type PutRequest struct {
// contains filtered or unexported fields
}
func NewPutRequest ¶ added in v0.6.0
func NewPutRequest(url string, opts ...PutRequestOption) *PutRequest
func (*PutRequest) Request ¶
func (req *PutRequest) Request(c *api.Context, request *http_client.Request, historyRequest []BuilderRequest, resultMap map[string]any) (BuilderRequest, error)
func (*PutRequest) Response ¶
func (req *PutRequest) Response() *http_client.Response
type PutRequestOption ¶ added in v0.6.0
type PutRequestOption func(options *PutRequestOptions)
func PutRequestWithBodyForm ¶ added in v0.6.0
func PutRequestWithBodyForm(bodyFormFunc BodyFormFunc) PutRequestOption
func PutRequestWithHeadersForm ¶ added in v0.6.0
func PutRequestWithHeadersForm(headersFormFunc HeadersFormFunc) PutRequestOption
func PutRequestWithUrlTransferFunc ¶ added in v0.6.0
func PutRequestWithUrlTransferFunc(urlTransferFunc UrlTransferFunc) PutRequestOption
type PutRequestOptions ¶ added in v0.6.0
type PutRequestOptions struct {
// contains filtered or unexported fields
}
type QueryParamsFormFunc ¶ added in v0.6.0
type QueryParamsFormFunc func(c *api.Context, historyRequest []BuilderRequest, resultMap map[string]any) (map[string]string, error)
func FormQueryParamsWithTenantIDAndUserIDFunc ¶ added in v0.6.0
func FormQueryParamsWithTenantIDAndUserIDFunc(tenantIDFieldName string, userIDFieldName string) QueryParamsFormFunc
type RequestResponseCallback ¶ added in v0.4.0
type RequestResponseCallback func(c *api.Context, response *http_client.Response, historyRequests []BuilderRequest, resultMap map[string]any) error
type ResponseErrorCallback ¶ added in v0.4.0
type ResponseSuccessCallback ¶ added in v0.4.0
type ResponseSuccessCallback func(c *api.Context, historyRequests []BuilderRequest, resultMap map[string]any)
type UrlTransferFunc ¶ added in v0.6.0
Click to show internal directories.
Click to hide internal directories.