Documentation ¶
Index ¶
- type Client
- func (a *Client) CreateProduct(params *CreateProductParams, opts ...ClientOption) (*CreateProductCreated, error)
- func (a *Client) DeleteProduct(params *DeleteProductParams, opts ...ClientOption) (*DeleteProductNoContent, error)
- func (a *Client) GetProduct(params *GetProductParams, opts ...ClientOption) (*GetProductOK, error)
- func (a *Client) GetProducts(params *GetProductsParams, opts ...ClientOption) (*GetProductsOK, error)
- func (a *Client) SetTransport(transport runtime.ClientTransport)
- func (a *Client) UpdateProduct(params *UpdateProductParams, opts ...ClientOption) (*UpdateProductOK, error)
- type ClientOption
- type ClientService
- type CreateProductBadRequest
- func (o *CreateProductBadRequest) Code() int
- func (o *CreateProductBadRequest) Error() string
- func (o *CreateProductBadRequest) GetPayload() *models.GRPCServiceError
- func (o *CreateProductBadRequest) IsClientError() bool
- func (o *CreateProductBadRequest) IsCode(code int) bool
- func (o *CreateProductBadRequest) IsRedirect() bool
- func (o *CreateProductBadRequest) IsServerError() bool
- func (o *CreateProductBadRequest) IsSuccess() bool
- func (o *CreateProductBadRequest) String() string
- type CreateProductCreated
- func (o *CreateProductCreated) Code() int
- func (o *CreateProductCreated) Error() string
- func (o *CreateProductCreated) GetPayload() *models.Product
- func (o *CreateProductCreated) IsClientError() bool
- func (o *CreateProductCreated) IsCode(code int) bool
- func (o *CreateProductCreated) IsRedirect() bool
- func (o *CreateProductCreated) IsServerError() bool
- func (o *CreateProductCreated) IsSuccess() bool
- func (o *CreateProductCreated) String() string
- type CreateProductParams
- func (o *CreateProductParams) SetBody(body *models.Product)
- func (o *CreateProductParams) SetContext(ctx context.Context)
- func (o *CreateProductParams) SetDefaults()
- func (o *CreateProductParams) SetHTTPClient(client *http.Client)
- func (o *CreateProductParams) SetTimeout(timeout time.Duration)
- func (o *CreateProductParams) WithBody(body *models.Product) *CreateProductParams
- func (o *CreateProductParams) WithContext(ctx context.Context) *CreateProductParams
- func (o *CreateProductParams) WithDefaults() *CreateProductParams
- func (o *CreateProductParams) WithHTTPClient(client *http.Client) *CreateProductParams
- func (o *CreateProductParams) WithTimeout(timeout time.Duration) *CreateProductParams
- func (o *CreateProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type CreateProductReader
- type CreateProductUnprocessableEntity
- func (o *CreateProductUnprocessableEntity) Code() int
- func (o *CreateProductUnprocessableEntity) Error() string
- func (o *CreateProductUnprocessableEntity) GetPayload() *models.ValidationErrors
- func (o *CreateProductUnprocessableEntity) IsClientError() bool
- func (o *CreateProductUnprocessableEntity) IsCode(code int) bool
- func (o *CreateProductUnprocessableEntity) IsRedirect() bool
- func (o *CreateProductUnprocessableEntity) IsServerError() bool
- func (o *CreateProductUnprocessableEntity) IsSuccess() bool
- func (o *CreateProductUnprocessableEntity) String() string
- type DeleteProductNoContent
- func (o *DeleteProductNoContent) Code() int
- func (o *DeleteProductNoContent) Error() string
- func (o *DeleteProductNoContent) IsClientError() bool
- func (o *DeleteProductNoContent) IsCode(code int) bool
- func (o *DeleteProductNoContent) IsRedirect() bool
- func (o *DeleteProductNoContent) IsServerError() bool
- func (o *DeleteProductNoContent) IsSuccess() bool
- func (o *DeleteProductNoContent) String() string
- type DeleteProductNotFound
- func (o *DeleteProductNotFound) Code() int
- func (o *DeleteProductNotFound) Error() string
- func (o *DeleteProductNotFound) GetPayload() *models.ProductNotFoundError
- func (o *DeleteProductNotFound) IsClientError() bool
- func (o *DeleteProductNotFound) IsCode(code int) bool
- func (o *DeleteProductNotFound) IsRedirect() bool
- func (o *DeleteProductNotFound) IsServerError() bool
- func (o *DeleteProductNotFound) IsSuccess() bool
- func (o *DeleteProductNotFound) String() string
- type DeleteProductParams
- func (o *DeleteProductParams) SetContext(ctx context.Context)
- func (o *DeleteProductParams) SetDefaults()
- func (o *DeleteProductParams) SetHTTPClient(client *http.Client)
- func (o *DeleteProductParams) SetID(id int64)
- func (o *DeleteProductParams) SetTimeout(timeout time.Duration)
- func (o *DeleteProductParams) WithContext(ctx context.Context) *DeleteProductParams
- func (o *DeleteProductParams) WithDefaults() *DeleteProductParams
- func (o *DeleteProductParams) WithHTTPClient(client *http.Client) *DeleteProductParams
- func (o *DeleteProductParams) WithID(id int64) *DeleteProductParams
- func (o *DeleteProductParams) WithTimeout(timeout time.Duration) *DeleteProductParams
- func (o *DeleteProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type DeleteProductReader
- type GetProductBadRequest
- func (o *GetProductBadRequest) Code() int
- func (o *GetProductBadRequest) Error() string
- func (o *GetProductBadRequest) GetPayload() *models.GRPCServiceError
- func (o *GetProductBadRequest) IsClientError() bool
- func (o *GetProductBadRequest) IsCode(code int) bool
- func (o *GetProductBadRequest) IsRedirect() bool
- func (o *GetProductBadRequest) IsServerError() bool
- func (o *GetProductBadRequest) IsSuccess() bool
- func (o *GetProductBadRequest) String() string
- type GetProductInternalServerError
- func (o *GetProductInternalServerError) Code() int
- func (o *GetProductInternalServerError) Error() string
- func (o *GetProductInternalServerError) GetPayload() *models.GenericError
- func (o *GetProductInternalServerError) IsClientError() bool
- func (o *GetProductInternalServerError) IsCode(code int) bool
- func (o *GetProductInternalServerError) IsRedirect() bool
- func (o *GetProductInternalServerError) IsServerError() bool
- func (o *GetProductInternalServerError) IsSuccess() bool
- func (o *GetProductInternalServerError) String() string
- type GetProductNotFound
- func (o *GetProductNotFound) Code() int
- func (o *GetProductNotFound) Error() string
- func (o *GetProductNotFound) GetPayload() *models.ProductNotFoundError
- func (o *GetProductNotFound) IsClientError() bool
- func (o *GetProductNotFound) IsCode(code int) bool
- func (o *GetProductNotFound) IsRedirect() bool
- func (o *GetProductNotFound) IsServerError() bool
- func (o *GetProductNotFound) IsSuccess() bool
- func (o *GetProductNotFound) String() string
- type GetProductOK
- func (o *GetProductOK) Code() int
- func (o *GetProductOK) Error() string
- func (o *GetProductOK) GetPayload() *models.Product
- func (o *GetProductOK) IsClientError() bool
- func (o *GetProductOK) IsCode(code int) bool
- func (o *GetProductOK) IsRedirect() bool
- func (o *GetProductOK) IsServerError() bool
- func (o *GetProductOK) IsSuccess() bool
- func (o *GetProductOK) String() string
- type GetProductParams
- func (o *GetProductParams) SetContext(ctx context.Context)
- func (o *GetProductParams) SetCurrency(currency *string)
- func (o *GetProductParams) SetDefaults()
- func (o *GetProductParams) SetHTTPClient(client *http.Client)
- func (o *GetProductParams) SetID(id int64)
- func (o *GetProductParams) SetTimeout(timeout time.Duration)
- func (o *GetProductParams) WithContext(ctx context.Context) *GetProductParams
- func (o *GetProductParams) WithCurrency(currency *string) *GetProductParams
- func (o *GetProductParams) WithDefaults() *GetProductParams
- func (o *GetProductParams) WithHTTPClient(client *http.Client) *GetProductParams
- func (o *GetProductParams) WithID(id int64) *GetProductParams
- func (o *GetProductParams) WithTimeout(timeout time.Duration) *GetProductParams
- func (o *GetProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type GetProductReader
- type GetProductsBadRequest
- func (o *GetProductsBadRequest) Code() int
- func (o *GetProductsBadRequest) Error() string
- func (o *GetProductsBadRequest) GetPayload() *models.GRPCServiceError
- func (o *GetProductsBadRequest) IsClientError() bool
- func (o *GetProductsBadRequest) IsCode(code int) bool
- func (o *GetProductsBadRequest) IsRedirect() bool
- func (o *GetProductsBadRequest) IsServerError() bool
- func (o *GetProductsBadRequest) IsSuccess() bool
- func (o *GetProductsBadRequest) String() string
- type GetProductsOK
- func (o *GetProductsOK) Code() int
- func (o *GetProductsOK) Error() string
- func (o *GetProductsOK) GetPayload() []*models.Product
- func (o *GetProductsOK) IsClientError() bool
- func (o *GetProductsOK) IsCode(code int) bool
- func (o *GetProductsOK) IsRedirect() bool
- func (o *GetProductsOK) IsServerError() bool
- func (o *GetProductsOK) IsSuccess() bool
- func (o *GetProductsOK) String() string
- type GetProductsParams
- func (o *GetProductsParams) SetContext(ctx context.Context)
- func (o *GetProductsParams) SetCurrency(currency *string)
- func (o *GetProductsParams) SetDefaults()
- func (o *GetProductsParams) SetHTTPClient(client *http.Client)
- func (o *GetProductsParams) SetTimeout(timeout time.Duration)
- func (o *GetProductsParams) WithContext(ctx context.Context) *GetProductsParams
- func (o *GetProductsParams) WithCurrency(currency *string) *GetProductsParams
- func (o *GetProductsParams) WithDefaults() *GetProductsParams
- func (o *GetProductsParams) WithHTTPClient(client *http.Client) *GetProductsParams
- func (o *GetProductsParams) WithTimeout(timeout time.Duration) *GetProductsParams
- func (o *GetProductsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type GetProductsReader
- type UpdateProductBadRequest
- func (o *UpdateProductBadRequest) Code() int
- func (o *UpdateProductBadRequest) Error() string
- func (o *UpdateProductBadRequest) GetPayload() *models.GRPCServiceError
- func (o *UpdateProductBadRequest) IsClientError() bool
- func (o *UpdateProductBadRequest) IsCode(code int) bool
- func (o *UpdateProductBadRequest) IsRedirect() bool
- func (o *UpdateProductBadRequest) IsServerError() bool
- func (o *UpdateProductBadRequest) IsSuccess() bool
- func (o *UpdateProductBadRequest) String() string
- type UpdateProductNotFound
- func (o *UpdateProductNotFound) Code() int
- func (o *UpdateProductNotFound) Error() string
- func (o *UpdateProductNotFound) GetPayload() *models.GenericError
- func (o *UpdateProductNotFound) IsClientError() bool
- func (o *UpdateProductNotFound) IsCode(code int) bool
- func (o *UpdateProductNotFound) IsRedirect() bool
- func (o *UpdateProductNotFound) IsServerError() bool
- func (o *UpdateProductNotFound) IsSuccess() bool
- func (o *UpdateProductNotFound) String() string
- type UpdateProductOK
- func (o *UpdateProductOK) Code() int
- func (o *UpdateProductOK) Error() string
- func (o *UpdateProductOK) GetPayload() *models.Product
- func (o *UpdateProductOK) IsClientError() bool
- func (o *UpdateProductOK) IsCode(code int) bool
- func (o *UpdateProductOK) IsRedirect() bool
- func (o *UpdateProductOK) IsServerError() bool
- func (o *UpdateProductOK) IsSuccess() bool
- func (o *UpdateProductOK) String() string
- type UpdateProductParams
- func (o *UpdateProductParams) SetBody(body *models.Product)
- func (o *UpdateProductParams) SetContext(ctx context.Context)
- func (o *UpdateProductParams) SetDefaults()
- func (o *UpdateProductParams) SetHTTPClient(client *http.Client)
- func (o *UpdateProductParams) SetID(id int64)
- func (o *UpdateProductParams) SetTimeout(timeout time.Duration)
- func (o *UpdateProductParams) WithBody(body *models.Product) *UpdateProductParams
- func (o *UpdateProductParams) WithContext(ctx context.Context) *UpdateProductParams
- func (o *UpdateProductParams) WithDefaults() *UpdateProductParams
- func (o *UpdateProductParams) WithHTTPClient(client *http.Client) *UpdateProductParams
- func (o *UpdateProductParams) WithID(id int64) *UpdateProductParams
- func (o *UpdateProductParams) WithTimeout(timeout time.Duration) *UpdateProductParams
- func (o *UpdateProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
- type UpdateProductReader
- type UpdateProductUnprocessableEntity
- func (o *UpdateProductUnprocessableEntity) Code() int
- func (o *UpdateProductUnprocessableEntity) Error() string
- func (o *UpdateProductUnprocessableEntity) GetPayload() *models.ValidationErrors
- func (o *UpdateProductUnprocessableEntity) IsClientError() bool
- func (o *UpdateProductUnprocessableEntity) IsCode(code int) bool
- func (o *UpdateProductUnprocessableEntity) IsRedirect() bool
- func (o *UpdateProductUnprocessableEntity) IsServerError() bool
- func (o *UpdateProductUnprocessableEntity) IsSuccess() bool
- func (o *UpdateProductUnprocessableEntity) String() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for products API
func (*Client) CreateProduct ¶
func (a *Client) CreateProduct(params *CreateProductParams, opts ...ClientOption) (*CreateProductCreated, error)
CreateProduct creates a new product
func (*Client) DeleteProduct ¶
func (a *Client) DeleteProduct(params *DeleteProductParams, opts ...ClientOption) (*DeleteProductNoContent, error)
DeleteProduct deletes a product
func (*Client) GetProduct ¶
func (a *Client) GetProduct(params *GetProductParams, opts ...ClientOption) (*GetProductOK, error)
GetProduct returns a single product
func (*Client) GetProducts ¶
func (a *Client) GetProducts(params *GetProductsParams, opts ...ClientOption) (*GetProductsOK, error)
GetProducts returns a list of products
func (*Client) SetTransport ¶
func (a *Client) SetTransport(transport runtime.ClientTransport)
SetTransport changes the transport on the client
func (*Client) UpdateProduct ¶
func (a *Client) UpdateProduct(params *UpdateProductParams, opts ...ClientOption) (*UpdateProductOK, error)
UpdateProduct updates a product details
type ClientOption ¶
type ClientOption func(*runtime.ClientOperation)
ClientOption is the option for Client methods
type ClientService ¶
type ClientService interface { CreateProduct(params *CreateProductParams, opts ...ClientOption) (*CreateProductCreated, error) DeleteProduct(params *DeleteProductParams, opts ...ClientOption) (*DeleteProductNoContent, error) GetProduct(params *GetProductParams, opts ...ClientOption) (*GetProductOK, error) GetProducts(params *GetProductsParams, opts ...ClientOption) (*GetProductsOK, error) UpdateProduct(params *UpdateProductParams, opts ...ClientOption) (*UpdateProductOK, error) SetTransport(transport runtime.ClientTransport) }
ClientService is the interface for Client methods
func New ¶
func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService
New creates a new products API client.
type CreateProductBadRequest ¶ added in v1.0.1
type CreateProductBadRequest struct {
Payload *models.GRPCServiceError
}
CreateProductBadRequest describes a response with status code 400, with default header values.
CreateProductBadRequest create product bad request
func NewCreateProductBadRequest ¶ added in v1.0.1
func NewCreateProductBadRequest() *CreateProductBadRequest
NewCreateProductBadRequest creates a CreateProductBadRequest with default headers values
func (*CreateProductBadRequest) Code ¶ added in v1.2.0
func (o *CreateProductBadRequest) Code() int
Code gets the status code for the create product bad request response
func (*CreateProductBadRequest) Error ¶ added in v1.0.1
func (o *CreateProductBadRequest) Error() string
func (*CreateProductBadRequest) GetPayload ¶ added in v1.0.1
func (o *CreateProductBadRequest) GetPayload() *models.GRPCServiceError
func (*CreateProductBadRequest) IsClientError ¶ added in v1.0.1
func (o *CreateProductBadRequest) IsClientError() bool
IsClientError returns true when this create product bad request response has a 4xx status code
func (*CreateProductBadRequest) IsCode ¶ added in v1.0.1
func (o *CreateProductBadRequest) IsCode(code int) bool
IsCode returns true when this create product bad request response a status code equal to that given
func (*CreateProductBadRequest) IsRedirect ¶ added in v1.0.1
func (o *CreateProductBadRequest) IsRedirect() bool
IsRedirect returns true when this create product bad request response has a 3xx status code
func (*CreateProductBadRequest) IsServerError ¶ added in v1.0.1
func (o *CreateProductBadRequest) IsServerError() bool
IsServerError returns true when this create product bad request response has a 5xx status code
func (*CreateProductBadRequest) IsSuccess ¶ added in v1.0.1
func (o *CreateProductBadRequest) IsSuccess() bool
IsSuccess returns true when this create product bad request response has a 2xx status code
func (*CreateProductBadRequest) String ¶ added in v1.0.1
func (o *CreateProductBadRequest) String() string
type CreateProductCreated ¶
CreateProductCreated describes a response with status code 201, with default header values.
Data structure is representing a single product.
func NewCreateProductCreated ¶
func NewCreateProductCreated() *CreateProductCreated
NewCreateProductCreated creates a CreateProductCreated with default headers values
func (*CreateProductCreated) Code ¶ added in v1.2.0
func (o *CreateProductCreated) Code() int
Code gets the status code for the create product created response
func (*CreateProductCreated) Error ¶
func (o *CreateProductCreated) Error() string
func (*CreateProductCreated) GetPayload ¶
func (o *CreateProductCreated) GetPayload() *models.Product
func (*CreateProductCreated) IsClientError ¶
func (o *CreateProductCreated) IsClientError() bool
IsClientError returns true when this create product created response has a 4xx status code
func (*CreateProductCreated) IsCode ¶
func (o *CreateProductCreated) IsCode(code int) bool
IsCode returns true when this create product created response a status code equal to that given
func (*CreateProductCreated) IsRedirect ¶
func (o *CreateProductCreated) IsRedirect() bool
IsRedirect returns true when this create product created response has a 3xx status code
func (*CreateProductCreated) IsServerError ¶
func (o *CreateProductCreated) IsServerError() bool
IsServerError returns true when this create product created response has a 5xx status code
func (*CreateProductCreated) IsSuccess ¶
func (o *CreateProductCreated) IsSuccess() bool
IsSuccess returns true when this create product created response has a 2xx status code
func (*CreateProductCreated) String ¶
func (o *CreateProductCreated) String() string
type CreateProductParams ¶
type CreateProductParams struct { // Body. Body *models.Product Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
CreateProductParams contains all the parameters to send to the API endpoint
for the create product operation. Typically these are written to a http.Request.
func NewCreateProductParams ¶
func NewCreateProductParams() *CreateProductParams
NewCreateProductParams creates a new CreateProductParams object, with the default timeout for this client.
Default values are not hydrated, since defaults are normally applied by the API server side.
To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewCreateProductParamsWithContext ¶
func NewCreateProductParamsWithContext(ctx context.Context) *CreateProductParams
NewCreateProductParamsWithContext creates a new CreateProductParams object with the ability to set a context for a request.
func NewCreateProductParamsWithHTTPClient ¶
func NewCreateProductParamsWithHTTPClient(client *http.Client) *CreateProductParams
NewCreateProductParamsWithHTTPClient creates a new CreateProductParams object with the ability to set a custom HTTPClient for a request.
func NewCreateProductParamsWithTimeout ¶
func NewCreateProductParamsWithTimeout(timeout time.Duration) *CreateProductParams
NewCreateProductParamsWithTimeout creates a new CreateProductParams object with the ability to set a timeout on a request.
func (*CreateProductParams) SetBody ¶
func (o *CreateProductParams) SetBody(body *models.Product)
SetBody adds the body to the create product params
func (*CreateProductParams) SetContext ¶
func (o *CreateProductParams) SetContext(ctx context.Context)
SetContext adds the context to the create product params
func (*CreateProductParams) SetDefaults ¶
func (o *CreateProductParams) SetDefaults()
SetDefaults hydrates default values in the create product params (not the query body).
All values with no default are reset to their zero value.
func (*CreateProductParams) SetHTTPClient ¶
func (o *CreateProductParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the create product params
func (*CreateProductParams) SetTimeout ¶
func (o *CreateProductParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the create product params
func (*CreateProductParams) WithBody ¶
func (o *CreateProductParams) WithBody(body *models.Product) *CreateProductParams
WithBody adds the body to the create product params
func (*CreateProductParams) WithContext ¶
func (o *CreateProductParams) WithContext(ctx context.Context) *CreateProductParams
WithContext adds the context to the create product params
func (*CreateProductParams) WithDefaults ¶
func (o *CreateProductParams) WithDefaults() *CreateProductParams
WithDefaults hydrates default values in the create product params (not the query body).
All values with no default are reset to their zero value.
func (*CreateProductParams) WithHTTPClient ¶
func (o *CreateProductParams) WithHTTPClient(client *http.Client) *CreateProductParams
WithHTTPClient adds the HTTPClient to the create product params
func (*CreateProductParams) WithTimeout ¶
func (o *CreateProductParams) WithTimeout(timeout time.Duration) *CreateProductParams
WithTimeout adds the timeout to the create product params
func (*CreateProductParams) WriteToRequest ¶
func (o *CreateProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type CreateProductReader ¶
type CreateProductReader struct {
// contains filtered or unexported fields
}
CreateProductReader is a Reader for the CreateProduct structure.
func (*CreateProductReader) ReadResponse ¶
func (o *CreateProductReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type CreateProductUnprocessableEntity ¶
type CreateProductUnprocessableEntity struct {
Payload *models.ValidationErrors
}
CreateProductUnprocessableEntity describes a response with status code 422, with default header values.
Validation errors are an array of strings.
func NewCreateProductUnprocessableEntity ¶
func NewCreateProductUnprocessableEntity() *CreateProductUnprocessableEntity
NewCreateProductUnprocessableEntity creates a CreateProductUnprocessableEntity with default headers values
func (*CreateProductUnprocessableEntity) Code ¶ added in v1.2.0
func (o *CreateProductUnprocessableEntity) Code() int
Code gets the status code for the create product unprocessable entity response
func (*CreateProductUnprocessableEntity) Error ¶
func (o *CreateProductUnprocessableEntity) Error() string
func (*CreateProductUnprocessableEntity) GetPayload ¶
func (o *CreateProductUnprocessableEntity) GetPayload() *models.ValidationErrors
func (*CreateProductUnprocessableEntity) IsClientError ¶
func (o *CreateProductUnprocessableEntity) IsClientError() bool
IsClientError returns true when this create product unprocessable entity response has a 4xx status code
func (*CreateProductUnprocessableEntity) IsCode ¶
func (o *CreateProductUnprocessableEntity) IsCode(code int) bool
IsCode returns true when this create product unprocessable entity response a status code equal to that given
func (*CreateProductUnprocessableEntity) IsRedirect ¶
func (o *CreateProductUnprocessableEntity) IsRedirect() bool
IsRedirect returns true when this create product unprocessable entity response has a 3xx status code
func (*CreateProductUnprocessableEntity) IsServerError ¶
func (o *CreateProductUnprocessableEntity) IsServerError() bool
IsServerError returns true when this create product unprocessable entity response has a 5xx status code
func (*CreateProductUnprocessableEntity) IsSuccess ¶
func (o *CreateProductUnprocessableEntity) IsSuccess() bool
IsSuccess returns true when this create product unprocessable entity response has a 2xx status code
func (*CreateProductUnprocessableEntity) String ¶
func (o *CreateProductUnprocessableEntity) String() string
type DeleteProductNoContent ¶
type DeleteProductNoContent struct { }
DeleteProductNoContent describes a response with status code 204, with default header values.
Empty response has no data.
func NewDeleteProductNoContent ¶
func NewDeleteProductNoContent() *DeleteProductNoContent
NewDeleteProductNoContent creates a DeleteProductNoContent with default headers values
func (*DeleteProductNoContent) Code ¶ added in v1.2.0
func (o *DeleteProductNoContent) Code() int
Code gets the status code for the delete product no content response
func (*DeleteProductNoContent) Error ¶
func (o *DeleteProductNoContent) Error() string
func (*DeleteProductNoContent) IsClientError ¶
func (o *DeleteProductNoContent) IsClientError() bool
IsClientError returns true when this delete product no content response has a 4xx status code
func (*DeleteProductNoContent) IsCode ¶
func (o *DeleteProductNoContent) IsCode(code int) bool
IsCode returns true when this delete product no content response a status code equal to that given
func (*DeleteProductNoContent) IsRedirect ¶
func (o *DeleteProductNoContent) IsRedirect() bool
IsRedirect returns true when this delete product no content response has a 3xx status code
func (*DeleteProductNoContent) IsServerError ¶
func (o *DeleteProductNoContent) IsServerError() bool
IsServerError returns true when this delete product no content response has a 5xx status code
func (*DeleteProductNoContent) IsSuccess ¶
func (o *DeleteProductNoContent) IsSuccess() bool
IsSuccess returns true when this delete product no content response has a 2xx status code
func (*DeleteProductNoContent) String ¶
func (o *DeleteProductNoContent) String() string
type DeleteProductNotFound ¶
type DeleteProductNotFound struct {
Payload *models.ProductNotFoundError
}
DeleteProductNotFound describes a response with status code 404, with default header values.
DeleteProductNotFound delete product not found
func NewDeleteProductNotFound ¶
func NewDeleteProductNotFound() *DeleteProductNotFound
NewDeleteProductNotFound creates a DeleteProductNotFound with default headers values
func (*DeleteProductNotFound) Code ¶ added in v1.2.0
func (o *DeleteProductNotFound) Code() int
Code gets the status code for the delete product not found response
func (*DeleteProductNotFound) Error ¶
func (o *DeleteProductNotFound) Error() string
func (*DeleteProductNotFound) GetPayload ¶
func (o *DeleteProductNotFound) GetPayload() *models.ProductNotFoundError
func (*DeleteProductNotFound) IsClientError ¶
func (o *DeleteProductNotFound) IsClientError() bool
IsClientError returns true when this delete product not found response has a 4xx status code
func (*DeleteProductNotFound) IsCode ¶
func (o *DeleteProductNotFound) IsCode(code int) bool
IsCode returns true when this delete product not found response a status code equal to that given
func (*DeleteProductNotFound) IsRedirect ¶
func (o *DeleteProductNotFound) IsRedirect() bool
IsRedirect returns true when this delete product not found response has a 3xx status code
func (*DeleteProductNotFound) IsServerError ¶
func (o *DeleteProductNotFound) IsServerError() bool
IsServerError returns true when this delete product not found response has a 5xx status code
func (*DeleteProductNotFound) IsSuccess ¶
func (o *DeleteProductNotFound) IsSuccess() bool
IsSuccess returns true when this delete product not found response has a 2xx status code
func (*DeleteProductNotFound) String ¶
func (o *DeleteProductNotFound) String() string
type DeleteProductParams ¶
type DeleteProductParams struct { // ID. // // Format: int64 ID int64 Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
DeleteProductParams contains all the parameters to send to the API endpoint
for the delete product operation. Typically these are written to a http.Request.
func NewDeleteProductParams ¶
func NewDeleteProductParams() *DeleteProductParams
NewDeleteProductParams creates a new DeleteProductParams object, with the default timeout for this client.
Default values are not hydrated, since defaults are normally applied by the API server side.
To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewDeleteProductParamsWithContext ¶
func NewDeleteProductParamsWithContext(ctx context.Context) *DeleteProductParams
NewDeleteProductParamsWithContext creates a new DeleteProductParams object with the ability to set a context for a request.
func NewDeleteProductParamsWithHTTPClient ¶
func NewDeleteProductParamsWithHTTPClient(client *http.Client) *DeleteProductParams
NewDeleteProductParamsWithHTTPClient creates a new DeleteProductParams object with the ability to set a custom HTTPClient for a request.
func NewDeleteProductParamsWithTimeout ¶
func NewDeleteProductParamsWithTimeout(timeout time.Duration) *DeleteProductParams
NewDeleteProductParamsWithTimeout creates a new DeleteProductParams object with the ability to set a timeout on a request.
func (*DeleteProductParams) SetContext ¶
func (o *DeleteProductParams) SetContext(ctx context.Context)
SetContext adds the context to the delete product params
func (*DeleteProductParams) SetDefaults ¶
func (o *DeleteProductParams) SetDefaults()
SetDefaults hydrates default values in the delete product params (not the query body).
All values with no default are reset to their zero value.
func (*DeleteProductParams) SetHTTPClient ¶
func (o *DeleteProductParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the delete product params
func (*DeleteProductParams) SetID ¶
func (o *DeleteProductParams) SetID(id int64)
SetID adds the id to the delete product params
func (*DeleteProductParams) SetTimeout ¶
func (o *DeleteProductParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the delete product params
func (*DeleteProductParams) WithContext ¶
func (o *DeleteProductParams) WithContext(ctx context.Context) *DeleteProductParams
WithContext adds the context to the delete product params
func (*DeleteProductParams) WithDefaults ¶
func (o *DeleteProductParams) WithDefaults() *DeleteProductParams
WithDefaults hydrates default values in the delete product params (not the query body).
All values with no default are reset to their zero value.
func (*DeleteProductParams) WithHTTPClient ¶
func (o *DeleteProductParams) WithHTTPClient(client *http.Client) *DeleteProductParams
WithHTTPClient adds the HTTPClient to the delete product params
func (*DeleteProductParams) WithID ¶
func (o *DeleteProductParams) WithID(id int64) *DeleteProductParams
WithID adds the id to the delete product params
func (*DeleteProductParams) WithTimeout ¶
func (o *DeleteProductParams) WithTimeout(timeout time.Duration) *DeleteProductParams
WithTimeout adds the timeout to the delete product params
func (*DeleteProductParams) WriteToRequest ¶
func (o *DeleteProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type DeleteProductReader ¶
type DeleteProductReader struct {
// contains filtered or unexported fields
}
DeleteProductReader is a Reader for the DeleteProduct structure.
func (*DeleteProductReader) ReadResponse ¶
func (o *DeleteProductReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type GetProductBadRequest ¶ added in v1.0.1
type GetProductBadRequest struct {
Payload *models.GRPCServiceError
}
GetProductBadRequest describes a response with status code 400, with default header values.
GetProductBadRequest get product bad request
func NewGetProductBadRequest ¶ added in v1.0.1
func NewGetProductBadRequest() *GetProductBadRequest
NewGetProductBadRequest creates a GetProductBadRequest with default headers values
func (*GetProductBadRequest) Code ¶ added in v1.2.0
func (o *GetProductBadRequest) Code() int
Code gets the status code for the get product bad request response
func (*GetProductBadRequest) Error ¶ added in v1.0.1
func (o *GetProductBadRequest) Error() string
func (*GetProductBadRequest) GetPayload ¶ added in v1.0.1
func (o *GetProductBadRequest) GetPayload() *models.GRPCServiceError
func (*GetProductBadRequest) IsClientError ¶ added in v1.0.1
func (o *GetProductBadRequest) IsClientError() bool
IsClientError returns true when this get product bad request response has a 4xx status code
func (*GetProductBadRequest) IsCode ¶ added in v1.0.1
func (o *GetProductBadRequest) IsCode(code int) bool
IsCode returns true when this get product bad request response a status code equal to that given
func (*GetProductBadRequest) IsRedirect ¶ added in v1.0.1
func (o *GetProductBadRequest) IsRedirect() bool
IsRedirect returns true when this get product bad request response has a 3xx status code
func (*GetProductBadRequest) IsServerError ¶ added in v1.0.1
func (o *GetProductBadRequest) IsServerError() bool
IsServerError returns true when this get product bad request response has a 5xx status code
func (*GetProductBadRequest) IsSuccess ¶ added in v1.0.1
func (o *GetProductBadRequest) IsSuccess() bool
IsSuccess returns true when this get product bad request response has a 2xx status code
func (*GetProductBadRequest) String ¶ added in v1.0.1
func (o *GetProductBadRequest) String() string
type GetProductInternalServerError ¶
type GetProductInternalServerError struct {
Payload *models.GenericError
}
GetProductInternalServerError describes a response with status code 500, with default header values.
GetProductInternalServerError get product internal server error
func NewGetProductInternalServerError ¶
func NewGetProductInternalServerError() *GetProductInternalServerError
NewGetProductInternalServerError creates a GetProductInternalServerError with default headers values
func (*GetProductInternalServerError) Code ¶ added in v1.2.0
func (o *GetProductInternalServerError) Code() int
Code gets the status code for the get product internal server error response
func (*GetProductInternalServerError) Error ¶
func (o *GetProductInternalServerError) Error() string
func (*GetProductInternalServerError) GetPayload ¶
func (o *GetProductInternalServerError) GetPayload() *models.GenericError
func (*GetProductInternalServerError) IsClientError ¶
func (o *GetProductInternalServerError) IsClientError() bool
IsClientError returns true when this get product internal server error response has a 4xx status code
func (*GetProductInternalServerError) IsCode ¶
func (o *GetProductInternalServerError) IsCode(code int) bool
IsCode returns true when this get product internal server error response a status code equal to that given
func (*GetProductInternalServerError) IsRedirect ¶
func (o *GetProductInternalServerError) IsRedirect() bool
IsRedirect returns true when this get product internal server error response has a 3xx status code
func (*GetProductInternalServerError) IsServerError ¶
func (o *GetProductInternalServerError) IsServerError() bool
IsServerError returns true when this get product internal server error response has a 5xx status code
func (*GetProductInternalServerError) IsSuccess ¶
func (o *GetProductInternalServerError) IsSuccess() bool
IsSuccess returns true when this get product internal server error response has a 2xx status code
func (*GetProductInternalServerError) String ¶
func (o *GetProductInternalServerError) String() string
type GetProductNotFound ¶
type GetProductNotFound struct {
Payload *models.ProductNotFoundError
}
GetProductNotFound describes a response with status code 404, with default header values.
GetProductNotFound get product not found
func NewGetProductNotFound ¶
func NewGetProductNotFound() *GetProductNotFound
NewGetProductNotFound creates a GetProductNotFound with default headers values
func (*GetProductNotFound) Code ¶ added in v1.2.0
func (o *GetProductNotFound) Code() int
Code gets the status code for the get product not found response
func (*GetProductNotFound) Error ¶
func (o *GetProductNotFound) Error() string
func (*GetProductNotFound) GetPayload ¶
func (o *GetProductNotFound) GetPayload() *models.ProductNotFoundError
func (*GetProductNotFound) IsClientError ¶
func (o *GetProductNotFound) IsClientError() bool
IsClientError returns true when this get product not found response has a 4xx status code
func (*GetProductNotFound) IsCode ¶
func (o *GetProductNotFound) IsCode(code int) bool
IsCode returns true when this get product not found response a status code equal to that given
func (*GetProductNotFound) IsRedirect ¶
func (o *GetProductNotFound) IsRedirect() bool
IsRedirect returns true when this get product not found response has a 3xx status code
func (*GetProductNotFound) IsServerError ¶
func (o *GetProductNotFound) IsServerError() bool
IsServerError returns true when this get product not found response has a 5xx status code
func (*GetProductNotFound) IsSuccess ¶
func (o *GetProductNotFound) IsSuccess() bool
IsSuccess returns true when this get product not found response has a 2xx status code
func (*GetProductNotFound) String ¶
func (o *GetProductNotFound) String() string
type GetProductOK ¶
GetProductOK describes a response with status code 200, with default header values.
Data structure is representing a single product.
func NewGetProductOK ¶
func NewGetProductOK() *GetProductOK
NewGetProductOK creates a GetProductOK with default headers values
func (*GetProductOK) Code ¶ added in v1.2.0
func (o *GetProductOK) Code() int
Code gets the status code for the get product o k response
func (*GetProductOK) Error ¶
func (o *GetProductOK) Error() string
func (*GetProductOK) GetPayload ¶
func (o *GetProductOK) GetPayload() *models.Product
func (*GetProductOK) IsClientError ¶
func (o *GetProductOK) IsClientError() bool
IsClientError returns true when this get product o k response has a 4xx status code
func (*GetProductOK) IsCode ¶
func (o *GetProductOK) IsCode(code int) bool
IsCode returns true when this get product o k response a status code equal to that given
func (*GetProductOK) IsRedirect ¶
func (o *GetProductOK) IsRedirect() bool
IsRedirect returns true when this get product o k response has a 3xx status code
func (*GetProductOK) IsServerError ¶
func (o *GetProductOK) IsServerError() bool
IsServerError returns true when this get product o k response has a 5xx status code
func (*GetProductOK) IsSuccess ¶
func (o *GetProductOK) IsSuccess() bool
IsSuccess returns true when this get product o k response has a 2xx status code
func (*GetProductOK) String ¶
func (o *GetProductOK) String() string
type GetProductParams ¶
type GetProductParams struct { // Currency. Currency *string // ID. // // Format: int64 ID int64 Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
GetProductParams contains all the parameters to send to the API endpoint
for the get product operation. Typically these are written to a http.Request.
func NewGetProductParams ¶
func NewGetProductParams() *GetProductParams
NewGetProductParams creates a new GetProductParams object, with the default timeout for this client.
Default values are not hydrated, since defaults are normally applied by the API server side.
To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewGetProductParamsWithContext ¶
func NewGetProductParamsWithContext(ctx context.Context) *GetProductParams
NewGetProductParamsWithContext creates a new GetProductParams object with the ability to set a context for a request.
func NewGetProductParamsWithHTTPClient ¶
func NewGetProductParamsWithHTTPClient(client *http.Client) *GetProductParams
NewGetProductParamsWithHTTPClient creates a new GetProductParams object with the ability to set a custom HTTPClient for a request.
func NewGetProductParamsWithTimeout ¶
func NewGetProductParamsWithTimeout(timeout time.Duration) *GetProductParams
NewGetProductParamsWithTimeout creates a new GetProductParams object with the ability to set a timeout on a request.
func (*GetProductParams) SetContext ¶
func (o *GetProductParams) SetContext(ctx context.Context)
SetContext adds the context to the get product params
func (*GetProductParams) SetCurrency ¶ added in v1.0.1
func (o *GetProductParams) SetCurrency(currency *string)
SetCurrency adds the currency to the get product params
func (*GetProductParams) SetDefaults ¶
func (o *GetProductParams) SetDefaults()
SetDefaults hydrates default values in the get product params (not the query body).
All values with no default are reset to their zero value.
func (*GetProductParams) SetHTTPClient ¶
func (o *GetProductParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the get product params
func (*GetProductParams) SetID ¶
func (o *GetProductParams) SetID(id int64)
SetID adds the id to the get product params
func (*GetProductParams) SetTimeout ¶
func (o *GetProductParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the get product params
func (*GetProductParams) WithContext ¶
func (o *GetProductParams) WithContext(ctx context.Context) *GetProductParams
WithContext adds the context to the get product params
func (*GetProductParams) WithCurrency ¶ added in v1.0.1
func (o *GetProductParams) WithCurrency(currency *string) *GetProductParams
WithCurrency adds the currency to the get product params
func (*GetProductParams) WithDefaults ¶
func (o *GetProductParams) WithDefaults() *GetProductParams
WithDefaults hydrates default values in the get product params (not the query body).
All values with no default are reset to their zero value.
func (*GetProductParams) WithHTTPClient ¶
func (o *GetProductParams) WithHTTPClient(client *http.Client) *GetProductParams
WithHTTPClient adds the HTTPClient to the get product params
func (*GetProductParams) WithID ¶
func (o *GetProductParams) WithID(id int64) *GetProductParams
WithID adds the id to the get product params
func (*GetProductParams) WithTimeout ¶
func (o *GetProductParams) WithTimeout(timeout time.Duration) *GetProductParams
WithTimeout adds the timeout to the get product params
func (*GetProductParams) WriteToRequest ¶
func (o *GetProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type GetProductReader ¶
type GetProductReader struct {
// contains filtered or unexported fields
}
GetProductReader is a Reader for the GetProduct structure.
func (*GetProductReader) ReadResponse ¶
func (o *GetProductReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type GetProductsBadRequest ¶ added in v1.0.1
type GetProductsBadRequest struct {
Payload *models.GRPCServiceError
}
GetProductsBadRequest describes a response with status code 400, with default header values.
GetProductsBadRequest get products bad request
func NewGetProductsBadRequest ¶ added in v1.0.1
func NewGetProductsBadRequest() *GetProductsBadRequest
NewGetProductsBadRequest creates a GetProductsBadRequest with default headers values
func (*GetProductsBadRequest) Code ¶ added in v1.2.0
func (o *GetProductsBadRequest) Code() int
Code gets the status code for the get products bad request response
func (*GetProductsBadRequest) Error ¶ added in v1.0.1
func (o *GetProductsBadRequest) Error() string
func (*GetProductsBadRequest) GetPayload ¶ added in v1.0.1
func (o *GetProductsBadRequest) GetPayload() *models.GRPCServiceError
func (*GetProductsBadRequest) IsClientError ¶ added in v1.0.1
func (o *GetProductsBadRequest) IsClientError() bool
IsClientError returns true when this get products bad request response has a 4xx status code
func (*GetProductsBadRequest) IsCode ¶ added in v1.0.1
func (o *GetProductsBadRequest) IsCode(code int) bool
IsCode returns true when this get products bad request response a status code equal to that given
func (*GetProductsBadRequest) IsRedirect ¶ added in v1.0.1
func (o *GetProductsBadRequest) IsRedirect() bool
IsRedirect returns true when this get products bad request response has a 3xx status code
func (*GetProductsBadRequest) IsServerError ¶ added in v1.0.1
func (o *GetProductsBadRequest) IsServerError() bool
IsServerError returns true when this get products bad request response has a 5xx status code
func (*GetProductsBadRequest) IsSuccess ¶ added in v1.0.1
func (o *GetProductsBadRequest) IsSuccess() bool
IsSuccess returns true when this get products bad request response has a 2xx status code
func (*GetProductsBadRequest) String ¶ added in v1.0.1
func (o *GetProductsBadRequest) String() string
type GetProductsOK ¶
GetProductsOK describes a response with status code 200, with default header values.
Data structure is representing a list of products.
func NewGetProductsOK ¶
func NewGetProductsOK() *GetProductsOK
NewGetProductsOK creates a GetProductsOK with default headers values
func (*GetProductsOK) Code ¶ added in v1.2.0
func (o *GetProductsOK) Code() int
Code gets the status code for the get products o k response
func (*GetProductsOK) Error ¶
func (o *GetProductsOK) Error() string
func (*GetProductsOK) GetPayload ¶
func (o *GetProductsOK) GetPayload() []*models.Product
func (*GetProductsOK) IsClientError ¶
func (o *GetProductsOK) IsClientError() bool
IsClientError returns true when this get products o k response has a 4xx status code
func (*GetProductsOK) IsCode ¶
func (o *GetProductsOK) IsCode(code int) bool
IsCode returns true when this get products o k response a status code equal to that given
func (*GetProductsOK) IsRedirect ¶
func (o *GetProductsOK) IsRedirect() bool
IsRedirect returns true when this get products o k response has a 3xx status code
func (*GetProductsOK) IsServerError ¶
func (o *GetProductsOK) IsServerError() bool
IsServerError returns true when this get products o k response has a 5xx status code
func (*GetProductsOK) IsSuccess ¶
func (o *GetProductsOK) IsSuccess() bool
IsSuccess returns true when this get products o k response has a 2xx status code
func (*GetProductsOK) String ¶
func (o *GetProductsOK) String() string
type GetProductsParams ¶
type GetProductsParams struct { // Currency. Currency *string Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
GetProductsParams contains all the parameters to send to the API endpoint
for the get products operation. Typically these are written to a http.Request.
func NewGetProductsParams ¶
func NewGetProductsParams() *GetProductsParams
NewGetProductsParams creates a new GetProductsParams object, with the default timeout for this client.
Default values are not hydrated, since defaults are normally applied by the API server side.
To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewGetProductsParamsWithContext ¶
func NewGetProductsParamsWithContext(ctx context.Context) *GetProductsParams
NewGetProductsParamsWithContext creates a new GetProductsParams object with the ability to set a context for a request.
func NewGetProductsParamsWithHTTPClient ¶
func NewGetProductsParamsWithHTTPClient(client *http.Client) *GetProductsParams
NewGetProductsParamsWithHTTPClient creates a new GetProductsParams object with the ability to set a custom HTTPClient for a request.
func NewGetProductsParamsWithTimeout ¶
func NewGetProductsParamsWithTimeout(timeout time.Duration) *GetProductsParams
NewGetProductsParamsWithTimeout creates a new GetProductsParams object with the ability to set a timeout on a request.
func (*GetProductsParams) SetContext ¶
func (o *GetProductsParams) SetContext(ctx context.Context)
SetContext adds the context to the get products params
func (*GetProductsParams) SetCurrency ¶ added in v1.0.1
func (o *GetProductsParams) SetCurrency(currency *string)
SetCurrency adds the currency to the get products params
func (*GetProductsParams) SetDefaults ¶
func (o *GetProductsParams) SetDefaults()
SetDefaults hydrates default values in the get products params (not the query body).
All values with no default are reset to their zero value.
func (*GetProductsParams) SetHTTPClient ¶
func (o *GetProductsParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the get products params
func (*GetProductsParams) SetTimeout ¶
func (o *GetProductsParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the get products params
func (*GetProductsParams) WithContext ¶
func (o *GetProductsParams) WithContext(ctx context.Context) *GetProductsParams
WithContext adds the context to the get products params
func (*GetProductsParams) WithCurrency ¶ added in v1.0.1
func (o *GetProductsParams) WithCurrency(currency *string) *GetProductsParams
WithCurrency adds the currency to the get products params
func (*GetProductsParams) WithDefaults ¶
func (o *GetProductsParams) WithDefaults() *GetProductsParams
WithDefaults hydrates default values in the get products params (not the query body).
All values with no default are reset to their zero value.
func (*GetProductsParams) WithHTTPClient ¶
func (o *GetProductsParams) WithHTTPClient(client *http.Client) *GetProductsParams
WithHTTPClient adds the HTTPClient to the get products params
func (*GetProductsParams) WithTimeout ¶
func (o *GetProductsParams) WithTimeout(timeout time.Duration) *GetProductsParams
WithTimeout adds the timeout to the get products params
func (*GetProductsParams) WriteToRequest ¶
func (o *GetProductsParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type GetProductsReader ¶
type GetProductsReader struct {
// contains filtered or unexported fields
}
GetProductsReader is a Reader for the GetProducts structure.
func (*GetProductsReader) ReadResponse ¶
func (o *GetProductsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type UpdateProductBadRequest ¶ added in v1.0.1
type UpdateProductBadRequest struct {
Payload *models.GRPCServiceError
}
UpdateProductBadRequest describes a response with status code 400, with default header values.
UpdateProductBadRequest update product bad request
func NewUpdateProductBadRequest ¶ added in v1.0.1
func NewUpdateProductBadRequest() *UpdateProductBadRequest
NewUpdateProductBadRequest creates a UpdateProductBadRequest with default headers values
func (*UpdateProductBadRequest) Code ¶ added in v1.2.0
func (o *UpdateProductBadRequest) Code() int
Code gets the status code for the update product bad request response
func (*UpdateProductBadRequest) Error ¶ added in v1.0.1
func (o *UpdateProductBadRequest) Error() string
func (*UpdateProductBadRequest) GetPayload ¶ added in v1.0.1
func (o *UpdateProductBadRequest) GetPayload() *models.GRPCServiceError
func (*UpdateProductBadRequest) IsClientError ¶ added in v1.0.1
func (o *UpdateProductBadRequest) IsClientError() bool
IsClientError returns true when this update product bad request response has a 4xx status code
func (*UpdateProductBadRequest) IsCode ¶ added in v1.0.1
func (o *UpdateProductBadRequest) IsCode(code int) bool
IsCode returns true when this update product bad request response a status code equal to that given
func (*UpdateProductBadRequest) IsRedirect ¶ added in v1.0.1
func (o *UpdateProductBadRequest) IsRedirect() bool
IsRedirect returns true when this update product bad request response has a 3xx status code
func (*UpdateProductBadRequest) IsServerError ¶ added in v1.0.1
func (o *UpdateProductBadRequest) IsServerError() bool
IsServerError returns true when this update product bad request response has a 5xx status code
func (*UpdateProductBadRequest) IsSuccess ¶ added in v1.0.1
func (o *UpdateProductBadRequest) IsSuccess() bool
IsSuccess returns true when this update product bad request response has a 2xx status code
func (*UpdateProductBadRequest) String ¶ added in v1.0.1
func (o *UpdateProductBadRequest) String() string
type UpdateProductNotFound ¶
type UpdateProductNotFound struct {
Payload *models.GenericError
}
UpdateProductNotFound describes a response with status code 404, with default header values.
UpdateProductNotFound update product not found
func NewUpdateProductNotFound ¶
func NewUpdateProductNotFound() *UpdateProductNotFound
NewUpdateProductNotFound creates a UpdateProductNotFound with default headers values
func (*UpdateProductNotFound) Code ¶ added in v1.2.0
func (o *UpdateProductNotFound) Code() int
Code gets the status code for the update product not found response
func (*UpdateProductNotFound) Error ¶
func (o *UpdateProductNotFound) Error() string
func (*UpdateProductNotFound) GetPayload ¶
func (o *UpdateProductNotFound) GetPayload() *models.GenericError
func (*UpdateProductNotFound) IsClientError ¶
func (o *UpdateProductNotFound) IsClientError() bool
IsClientError returns true when this update product not found response has a 4xx status code
func (*UpdateProductNotFound) IsCode ¶
func (o *UpdateProductNotFound) IsCode(code int) bool
IsCode returns true when this update product not found response a status code equal to that given
func (*UpdateProductNotFound) IsRedirect ¶
func (o *UpdateProductNotFound) IsRedirect() bool
IsRedirect returns true when this update product not found response has a 3xx status code
func (*UpdateProductNotFound) IsServerError ¶
func (o *UpdateProductNotFound) IsServerError() bool
IsServerError returns true when this update product not found response has a 5xx status code
func (*UpdateProductNotFound) IsSuccess ¶
func (o *UpdateProductNotFound) IsSuccess() bool
IsSuccess returns true when this update product not found response has a 2xx status code
func (*UpdateProductNotFound) String ¶
func (o *UpdateProductNotFound) String() string
type UpdateProductOK ¶
UpdateProductOK describes a response with status code 200, with default header values.
Data structure is representing a single product.
func NewUpdateProductOK ¶
func NewUpdateProductOK() *UpdateProductOK
NewUpdateProductOK creates a UpdateProductOK with default headers values
func (*UpdateProductOK) Code ¶ added in v1.2.0
func (o *UpdateProductOK) Code() int
Code gets the status code for the update product o k response
func (*UpdateProductOK) Error ¶
func (o *UpdateProductOK) Error() string
func (*UpdateProductOK) GetPayload ¶
func (o *UpdateProductOK) GetPayload() *models.Product
func (*UpdateProductOK) IsClientError ¶
func (o *UpdateProductOK) IsClientError() bool
IsClientError returns true when this update product o k response has a 4xx status code
func (*UpdateProductOK) IsCode ¶
func (o *UpdateProductOK) IsCode(code int) bool
IsCode returns true when this update product o k response a status code equal to that given
func (*UpdateProductOK) IsRedirect ¶
func (o *UpdateProductOK) IsRedirect() bool
IsRedirect returns true when this update product o k response has a 3xx status code
func (*UpdateProductOK) IsServerError ¶
func (o *UpdateProductOK) IsServerError() bool
IsServerError returns true when this update product o k response has a 5xx status code
func (*UpdateProductOK) IsSuccess ¶
func (o *UpdateProductOK) IsSuccess() bool
IsSuccess returns true when this update product o k response has a 2xx status code
func (*UpdateProductOK) String ¶
func (o *UpdateProductOK) String() string
type UpdateProductParams ¶
type UpdateProductParams struct { // Body. Body *models.Product // ID. // // Format: int64 ID int64 Context context.Context HTTPClient *http.Client // contains filtered or unexported fields }
UpdateProductParams contains all the parameters to send to the API endpoint
for the update product operation. Typically these are written to a http.Request.
func NewUpdateProductParams ¶
func NewUpdateProductParams() *UpdateProductParams
NewUpdateProductParams creates a new UpdateProductParams object, with the default timeout for this client.
Default values are not hydrated, since defaults are normally applied by the API server side.
To enforce default values in parameter, use SetDefaults or WithDefaults.
func NewUpdateProductParamsWithContext ¶
func NewUpdateProductParamsWithContext(ctx context.Context) *UpdateProductParams
NewUpdateProductParamsWithContext creates a new UpdateProductParams object with the ability to set a context for a request.
func NewUpdateProductParamsWithHTTPClient ¶
func NewUpdateProductParamsWithHTTPClient(client *http.Client) *UpdateProductParams
NewUpdateProductParamsWithHTTPClient creates a new UpdateProductParams object with the ability to set a custom HTTPClient for a request.
func NewUpdateProductParamsWithTimeout ¶
func NewUpdateProductParamsWithTimeout(timeout time.Duration) *UpdateProductParams
NewUpdateProductParamsWithTimeout creates a new UpdateProductParams object with the ability to set a timeout on a request.
func (*UpdateProductParams) SetBody ¶
func (o *UpdateProductParams) SetBody(body *models.Product)
SetBody adds the body to the update product params
func (*UpdateProductParams) SetContext ¶
func (o *UpdateProductParams) SetContext(ctx context.Context)
SetContext adds the context to the update product params
func (*UpdateProductParams) SetDefaults ¶
func (o *UpdateProductParams) SetDefaults()
SetDefaults hydrates default values in the update product params (not the query body).
All values with no default are reset to their zero value.
func (*UpdateProductParams) SetHTTPClient ¶
func (o *UpdateProductParams) SetHTTPClient(client *http.Client)
SetHTTPClient adds the HTTPClient to the update product params
func (*UpdateProductParams) SetID ¶
func (o *UpdateProductParams) SetID(id int64)
SetID adds the id to the update product params
func (*UpdateProductParams) SetTimeout ¶
func (o *UpdateProductParams) SetTimeout(timeout time.Duration)
SetTimeout adds the timeout to the update product params
func (*UpdateProductParams) WithBody ¶
func (o *UpdateProductParams) WithBody(body *models.Product) *UpdateProductParams
WithBody adds the body to the update product params
func (*UpdateProductParams) WithContext ¶
func (o *UpdateProductParams) WithContext(ctx context.Context) *UpdateProductParams
WithContext adds the context to the update product params
func (*UpdateProductParams) WithDefaults ¶
func (o *UpdateProductParams) WithDefaults() *UpdateProductParams
WithDefaults hydrates default values in the update product params (not the query body).
All values with no default are reset to their zero value.
func (*UpdateProductParams) WithHTTPClient ¶
func (o *UpdateProductParams) WithHTTPClient(client *http.Client) *UpdateProductParams
WithHTTPClient adds the HTTPClient to the update product params
func (*UpdateProductParams) WithID ¶
func (o *UpdateProductParams) WithID(id int64) *UpdateProductParams
WithID adds the id to the update product params
func (*UpdateProductParams) WithTimeout ¶
func (o *UpdateProductParams) WithTimeout(timeout time.Duration) *UpdateProductParams
WithTimeout adds the timeout to the update product params
func (*UpdateProductParams) WriteToRequest ¶
func (o *UpdateProductParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error
WriteToRequest writes these params to a swagger request
type UpdateProductReader ¶
type UpdateProductReader struct {
// contains filtered or unexported fields
}
UpdateProductReader is a Reader for the UpdateProduct structure.
func (*UpdateProductReader) ReadResponse ¶
func (o *UpdateProductReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error)
ReadResponse reads a server response into the received o.
type UpdateProductUnprocessableEntity ¶
type UpdateProductUnprocessableEntity struct {
Payload *models.ValidationErrors
}
UpdateProductUnprocessableEntity describes a response with status code 422, with default header values.
Validation errors are an array of strings.
func NewUpdateProductUnprocessableEntity ¶
func NewUpdateProductUnprocessableEntity() *UpdateProductUnprocessableEntity
NewUpdateProductUnprocessableEntity creates a UpdateProductUnprocessableEntity with default headers values
func (*UpdateProductUnprocessableEntity) Code ¶ added in v1.2.0
func (o *UpdateProductUnprocessableEntity) Code() int
Code gets the status code for the update product unprocessable entity response
func (*UpdateProductUnprocessableEntity) Error ¶
func (o *UpdateProductUnprocessableEntity) Error() string
func (*UpdateProductUnprocessableEntity) GetPayload ¶
func (o *UpdateProductUnprocessableEntity) GetPayload() *models.ValidationErrors
func (*UpdateProductUnprocessableEntity) IsClientError ¶
func (o *UpdateProductUnprocessableEntity) IsClientError() bool
IsClientError returns true when this update product unprocessable entity response has a 4xx status code
func (*UpdateProductUnprocessableEntity) IsCode ¶
func (o *UpdateProductUnprocessableEntity) IsCode(code int) bool
IsCode returns true when this update product unprocessable entity response a status code equal to that given
func (*UpdateProductUnprocessableEntity) IsRedirect ¶
func (o *UpdateProductUnprocessableEntity) IsRedirect() bool
IsRedirect returns true when this update product unprocessable entity response has a 3xx status code
func (*UpdateProductUnprocessableEntity) IsServerError ¶
func (o *UpdateProductUnprocessableEntity) IsServerError() bool
IsServerError returns true when this update product unprocessable entity response has a 5xx status code
func (*UpdateProductUnprocessableEntity) IsSuccess ¶
func (o *UpdateProductUnprocessableEntity) IsSuccess() bool
IsSuccess returns true when this update product unprocessable entity response has a 2xx status code
func (*UpdateProductUnprocessableEntity) String ¶
func (o *UpdateProductUnprocessableEntity) String() string