Documentation
¶
Overview ¶
Package v1 is a generated GoMock package.
Index ¶
- Constants
- func DecodeResponse[RESP any](ctx context.Context, response *http.Response) (interface{}, error)
- func EncodeRequest[REQ any](ctx context.Context, request *http.Request, req HTTPRequest[REQ]) error
- type Client
- type Endpoint
- type HTTPRequest
- type MockClient
- type MockClientMockRecorder
- type NilBody
Constants ¶
const ( // HTTPMethodPost is the HTTP POST method. HTTPMethodPost = "POST" // HTTPMethodGet is the HTTP GET method. HTTPMethodGet = "GET" // HTTPMethodPut is the HTTP PUT method. HTTPMethodPut = "PUT" // HTTPMethodDelete is the HTTP DELETE method. HTTPMethodDelete = "DELETE" )
Variables ¶
This section is empty.
Functions ¶
func DecodeResponse ¶
func EncodeRequest ¶
Types ¶
type Client ¶
Client interface provides a standard endpoint with request/response conversion capabilities
func NewHTTPClient ¶
func NewHTTPClient[REQ any, RESP any](method, path string, options ...http_transport.ClientOption) Client[REQ, RESP]
type Endpoint ¶
type HTTPRequest ¶
type MockClient ¶
MockClient is a mock of Client interface.
func NewMockClient ¶
func NewMockClient[REQ any, RESP any](ctrl *gomock.Controller) *MockClient[REQ, RESP]
NewMockClient creates a new mock instance.
func (*MockClient[REQ, RESP]) EXPECT ¶
func (m *MockClient[REQ, RESP]) EXPECT() *MockClientMockRecorder[REQ, RESP]
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockClient[REQ, RESP]) Endpoint ¶
func (m *MockClient[REQ, RESP]) Endpoint() Endpoint[REQ, RESP]
Endpoint mocks base method.
type MockClientMockRecorder ¶
MockClientMockRecorder is the mock recorder for MockClient.
func (*MockClientMockRecorder[REQ, RESP]) Endpoint ¶
func (mr *MockClientMockRecorder[REQ, RESP]) Endpoint() *gomock.Call
Endpoint indicates an expected call of Endpoint.