Documentation ¶
Index ¶
- Constants
- type CreateCategory
- type CreateCategoryBadRequest
- type CreateCategoryCreated
- type CreateCategoryHandler
- type CreateCategoryHandlerFunc
- type CreateCategoryParams
- type CreateCategoryURL
- func (o *CreateCategoryURL) Build() (*url.URL, error)
- func (o *CreateCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *CreateCategoryURL) Must(u *url.URL, err error) *url.URL
- func (o *CreateCategoryURL) SetBasePath(bp string)
- func (o *CreateCategoryURL) String() string
- func (o *CreateCategoryURL) StringFull(scheme, host string) string
- func (o *CreateCategoryURL) WithBasePath(bp string) *CreateCategoryURL
- type DeleteCategories
- type DeleteCategoriesHandler
- type DeleteCategoriesHandlerFunc
- type DeleteCategoriesNotFound
- type DeleteCategoriesOK
- type DeleteCategoriesParams
- type DeleteCategoriesURL
- func (o *DeleteCategoriesURL) Build() (*url.URL, error)
- func (o *DeleteCategoriesURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *DeleteCategoriesURL) Must(u *url.URL, err error) *url.URL
- func (o *DeleteCategoriesURL) SetBasePath(bp string)
- func (o *DeleteCategoriesURL) String() string
- func (o *DeleteCategoriesURL) StringFull(scheme, host string) string
- func (o *DeleteCategoriesURL) WithBasePath(bp string) *DeleteCategoriesURL
- type DeleteCategory
- type DeleteCategoryBadRequest
- type DeleteCategoryHandler
- type DeleteCategoryHandlerFunc
- type DeleteCategoryNotFound
- type DeleteCategoryOK
- type DeleteCategoryParams
- type DeleteCategoryURL
- func (o *DeleteCategoryURL) Build() (*url.URL, error)
- func (o *DeleteCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *DeleteCategoryURL) Must(u *url.URL, err error) *url.URL
- func (o *DeleteCategoryURL) SetBasePath(bp string)
- func (o *DeleteCategoryURL) String() string
- func (o *DeleteCategoryURL) StringFull(scheme, host string) string
- func (o *DeleteCategoryURL) WithBasePath(bp string) *DeleteCategoryURL
- type GetCategories
- type GetCategoriesHandler
- type GetCategoriesHandlerFunc
- type GetCategoriesNotFound
- type GetCategoriesOK
- type GetCategoriesParams
- type GetCategoriesURL
- func (o *GetCategoriesURL) Build() (*url.URL, error)
- func (o *GetCategoriesURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *GetCategoriesURL) Must(u *url.URL, err error) *url.URL
- func (o *GetCategoriesURL) SetBasePath(bp string)
- func (o *GetCategoriesURL) String() string
- func (o *GetCategoriesURL) StringFull(scheme, host string) string
- func (o *GetCategoriesURL) WithBasePath(bp string) *GetCategoriesURL
- type GetCategory
- type GetCategoryBadRequest
- type GetCategoryHandler
- type GetCategoryHandlerFunc
- type GetCategoryNotFound
- type GetCategoryOK
- type GetCategoryParams
- type GetCategoryURL
- func (o *GetCategoryURL) Build() (*url.URL, error)
- func (o *GetCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *GetCategoryURL) Must(u *url.URL, err error) *url.URL
- func (o *GetCategoryURL) SetBasePath(bp string)
- func (o *GetCategoryURL) String() string
- func (o *GetCategoryURL) StringFull(scheme, host string) string
- func (o *GetCategoryURL) WithBasePath(bp string) *GetCategoryURL
- type UpdateCategory
- type UpdateCategoryBadRequest
- type UpdateCategoryCreated
- type UpdateCategoryHandler
- type UpdateCategoryHandlerFunc
- type UpdateCategoryNotFound
- type UpdateCategoryParams
- type UpdateCategoryURL
- func (o *UpdateCategoryURL) Build() (*url.URL, error)
- func (o *UpdateCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *UpdateCategoryURL) Must(u *url.URL, err error) *url.URL
- func (o *UpdateCategoryURL) SetBasePath(bp string)
- func (o *UpdateCategoryURL) String() string
- func (o *UpdateCategoryURL) StringFull(scheme, host string) string
- func (o *UpdateCategoryURL) WithBasePath(bp string) *UpdateCategoryURL
Constants ¶
const CreateCategoryBadRequestCode int = 400
CreateCategoryBadRequestCode is the HTTP code returned for type CreateCategoryBadRequest
const CreateCategoryCreatedCode int = 201
CreateCategoryCreatedCode is the HTTP code returned for type CreateCategoryCreated
const DeleteCategoriesNotFoundCode int = 404
DeleteCategoriesNotFoundCode is the HTTP code returned for type DeleteCategoriesNotFound
const DeleteCategoriesOKCode int = 200
DeleteCategoriesOKCode is the HTTP code returned for type DeleteCategoriesOK
const DeleteCategoryBadRequestCode int = 400
DeleteCategoryBadRequestCode is the HTTP code returned for type DeleteCategoryBadRequest
const DeleteCategoryNotFoundCode int = 404
DeleteCategoryNotFoundCode is the HTTP code returned for type DeleteCategoryNotFound
const DeleteCategoryOKCode int = 200
DeleteCategoryOKCode is the HTTP code returned for type DeleteCategoryOK
const GetCategoriesNotFoundCode int = 404
GetCategoriesNotFoundCode is the HTTP code returned for type GetCategoriesNotFound
const GetCategoriesOKCode int = 200
GetCategoriesOKCode is the HTTP code returned for type GetCategoriesOK
const GetCategoryBadRequestCode int = 400
GetCategoryBadRequestCode is the HTTP code returned for type GetCategoryBadRequest
const GetCategoryNotFoundCode int = 404
GetCategoryNotFoundCode is the HTTP code returned for type GetCategoryNotFound
const GetCategoryOKCode int = 200
GetCategoryOKCode is the HTTP code returned for type GetCategoryOK
const UpdateCategoryBadRequestCode int = 400
UpdateCategoryBadRequestCode is the HTTP code returned for type UpdateCategoryBadRequest
const UpdateCategoryCreatedCode int = 201
UpdateCategoryCreatedCode is the HTTP code returned for type UpdateCategoryCreated
const UpdateCategoryNotFoundCode int = 404
UpdateCategoryNotFoundCode is the HTTP code returned for type UpdateCategoryNotFound
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateCategory ¶
type CreateCategory struct { Context *middleware.Context Handler CreateCategoryHandler }
CreateCategory swagger:route POST /categories Categories createCategory
Create a Category
func NewCreateCategory ¶
func NewCreateCategory(ctx *middleware.Context, handler CreateCategoryHandler) *CreateCategory
NewCreateCategory creates a new http.Handler for the create category operation
func (*CreateCategory) ServeHTTP ¶
func (o *CreateCategory) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type CreateCategoryBadRequest ¶
type CreateCategoryBadRequest struct { }
CreateCategoryBadRequest Invalid input
swagger:response createCategoryBadRequest
func NewCreateCategoryBadRequest ¶
func NewCreateCategoryBadRequest() *CreateCategoryBadRequest
NewCreateCategoryBadRequest creates CreateCategoryBadRequest with default headers values
func (*CreateCategoryBadRequest) WriteResponse ¶
func (o *CreateCategoryBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type CreateCategoryCreated ¶
type CreateCategoryCreated struct { /* In: Body */ Payload *models.Category `json:"body,omitempty"` }
CreateCategoryCreated Category Created
swagger:response createCategoryCreated
func NewCreateCategoryCreated ¶
func NewCreateCategoryCreated() *CreateCategoryCreated
NewCreateCategoryCreated creates CreateCategoryCreated with default headers values
func (*CreateCategoryCreated) SetPayload ¶
func (o *CreateCategoryCreated) SetPayload(payload *models.Category)
SetPayload sets the payload to the create category created response
func (*CreateCategoryCreated) WithPayload ¶
func (o *CreateCategoryCreated) WithPayload(payload *models.Category) *CreateCategoryCreated
WithPayload adds the payload to the create category created response
func (*CreateCategoryCreated) WriteResponse ¶
func (o *CreateCategoryCreated) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type CreateCategoryHandler ¶
type CreateCategoryHandler interface {
Handle(CreateCategoryParams) middleware.Responder
}
CreateCategoryHandler interface for that can handle valid create category params
type CreateCategoryHandlerFunc ¶
type CreateCategoryHandlerFunc func(CreateCategoryParams) middleware.Responder
CreateCategoryHandlerFunc turns a function with the right signature into a create category handler
func (CreateCategoryHandlerFunc) Handle ¶
func (fn CreateCategoryHandlerFunc) Handle(params CreateCategoryParams) middleware.Responder
Handle executing the request and returning a response
type CreateCategoryParams ¶
type CreateCategoryParams struct { // HTTP Request Object HTTPRequest *http.Request /*Category that needs to be added to the DB Required: true In: body */ Body *models.Category }
CreateCategoryParams contains all the bound params for the create category operation typically these are obtained from a http.Request
swagger:parameters createCategory
func NewCreateCategoryParams ¶
func NewCreateCategoryParams() CreateCategoryParams
NewCreateCategoryParams creates a new CreateCategoryParams object with the default values initialized.
func (*CreateCategoryParams) BindRequest ¶
func (o *CreateCategoryParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type CreateCategoryURL ¶
type CreateCategoryURL struct {
// contains filtered or unexported fields
}
CreateCategoryURL generates an URL for the create category operation
func (*CreateCategoryURL) Build ¶
func (o *CreateCategoryURL) Build() (*url.URL, error)
Build a url path and query string
func (*CreateCategoryURL) BuildFull ¶
func (o *CreateCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*CreateCategoryURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*CreateCategoryURL) SetBasePath ¶
func (o *CreateCategoryURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*CreateCategoryURL) String ¶
func (o *CreateCategoryURL) String() string
String returns the string representation of the path with query string
func (*CreateCategoryURL) StringFull ¶
func (o *CreateCategoryURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*CreateCategoryURL) WithBasePath ¶
func (o *CreateCategoryURL) WithBasePath(bp string) *CreateCategoryURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type DeleteCategories ¶
type DeleteCategories struct { Context *middleware.Context Handler DeleteCategoriesHandler }
DeleteCategories swagger:route DELETE /categories Categories deleteCategories
Delete all Categories ¶
a category deletion will also remove all of its subcategories.
func NewDeleteCategories ¶
func NewDeleteCategories(ctx *middleware.Context, handler DeleteCategoriesHandler) *DeleteCategories
NewDeleteCategories creates a new http.Handler for the delete categories operation
func (*DeleteCategories) ServeHTTP ¶
func (o *DeleteCategories) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type DeleteCategoriesHandler ¶
type DeleteCategoriesHandler interface {
Handle(DeleteCategoriesParams) middleware.Responder
}
DeleteCategoriesHandler interface for that can handle valid delete categories params
type DeleteCategoriesHandlerFunc ¶
type DeleteCategoriesHandlerFunc func(DeleteCategoriesParams) middleware.Responder
DeleteCategoriesHandlerFunc turns a function with the right signature into a delete categories handler
func (DeleteCategoriesHandlerFunc) Handle ¶
func (fn DeleteCategoriesHandlerFunc) Handle(params DeleteCategoriesParams) middleware.Responder
Handle executing the request and returning a response
type DeleteCategoriesNotFound ¶
type DeleteCategoriesNotFound struct { }
DeleteCategoriesNotFound No items found
swagger:response deleteCategoriesNotFound
func NewDeleteCategoriesNotFound ¶
func NewDeleteCategoriesNotFound() *DeleteCategoriesNotFound
NewDeleteCategoriesNotFound creates DeleteCategoriesNotFound with default headers values
func (*DeleteCategoriesNotFound) WriteResponse ¶
func (o *DeleteCategoriesNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type DeleteCategoriesOK ¶
type DeleteCategoriesOK struct { }
DeleteCategoriesOK Status Ok
swagger:response deleteCategoriesOK
func NewDeleteCategoriesOK ¶
func NewDeleteCategoriesOK() *DeleteCategoriesOK
NewDeleteCategoriesOK creates DeleteCategoriesOK with default headers values
func (*DeleteCategoriesOK) WriteResponse ¶
func (o *DeleteCategoriesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type DeleteCategoriesParams ¶
DeleteCategoriesParams contains all the bound params for the delete categories operation typically these are obtained from a http.Request
swagger:parameters deleteCategories
func NewDeleteCategoriesParams ¶
func NewDeleteCategoriesParams() DeleteCategoriesParams
NewDeleteCategoriesParams creates a new DeleteCategoriesParams object with the default values initialized.
func (*DeleteCategoriesParams) BindRequest ¶
func (o *DeleteCategoriesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type DeleteCategoriesURL ¶
type DeleteCategoriesURL struct {
// contains filtered or unexported fields
}
DeleteCategoriesURL generates an URL for the delete categories operation
func (*DeleteCategoriesURL) Build ¶
func (o *DeleteCategoriesURL) Build() (*url.URL, error)
Build a url path and query string
func (*DeleteCategoriesURL) BuildFull ¶
func (o *DeleteCategoriesURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*DeleteCategoriesURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*DeleteCategoriesURL) SetBasePath ¶
func (o *DeleteCategoriesURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*DeleteCategoriesURL) String ¶
func (o *DeleteCategoriesURL) String() string
String returns the string representation of the path with query string
func (*DeleteCategoriesURL) StringFull ¶
func (o *DeleteCategoriesURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*DeleteCategoriesURL) WithBasePath ¶
func (o *DeleteCategoriesURL) WithBasePath(bp string) *DeleteCategoriesURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type DeleteCategory ¶
type DeleteCategory struct { Context *middleware.Context Handler DeleteCategoryHandler }
DeleteCategory swagger:route DELETE /categories/{id} Categories deleteCategory
Delete Category ¶
A category deletion will also remove all of its subcategories.
func NewDeleteCategory ¶
func NewDeleteCategory(ctx *middleware.Context, handler DeleteCategoryHandler) *DeleteCategory
NewDeleteCategory creates a new http.Handler for the delete category operation
func (*DeleteCategory) ServeHTTP ¶
func (o *DeleteCategory) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type DeleteCategoryBadRequest ¶
type DeleteCategoryBadRequest struct { }
DeleteCategoryBadRequest Invalid input
swagger:response deleteCategoryBadRequest
func NewDeleteCategoryBadRequest ¶
func NewDeleteCategoryBadRequest() *DeleteCategoryBadRequest
NewDeleteCategoryBadRequest creates DeleteCategoryBadRequest with default headers values
func (*DeleteCategoryBadRequest) WriteResponse ¶
func (o *DeleteCategoryBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type DeleteCategoryHandler ¶
type DeleteCategoryHandler interface {
Handle(DeleteCategoryParams) middleware.Responder
}
DeleteCategoryHandler interface for that can handle valid delete category params
type DeleteCategoryHandlerFunc ¶
type DeleteCategoryHandlerFunc func(DeleteCategoryParams) middleware.Responder
DeleteCategoryHandlerFunc turns a function with the right signature into a delete category handler
func (DeleteCategoryHandlerFunc) Handle ¶
func (fn DeleteCategoryHandlerFunc) Handle(params DeleteCategoryParams) middleware.Responder
Handle executing the request and returning a response
type DeleteCategoryNotFound ¶
type DeleteCategoryNotFound struct { }
DeleteCategoryNotFound No items found
swagger:response deleteCategoryNotFound
func NewDeleteCategoryNotFound ¶
func NewDeleteCategoryNotFound() *DeleteCategoryNotFound
NewDeleteCategoryNotFound creates DeleteCategoryNotFound with default headers values
func (*DeleteCategoryNotFound) WriteResponse ¶
func (o *DeleteCategoryNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type DeleteCategoryOK ¶
type DeleteCategoryOK struct { }
DeleteCategoryOK Status Ok
swagger:response deleteCategoryOK
func NewDeleteCategoryOK ¶
func NewDeleteCategoryOK() *DeleteCategoryOK
NewDeleteCategoryOK creates DeleteCategoryOK with default headers values
func (*DeleteCategoryOK) WriteResponse ¶
func (o *DeleteCategoryOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type DeleteCategoryParams ¶
type DeleteCategoryParams struct { // HTTP Request Object HTTPRequest *http.Request /* Required: true In: path */ ID int64 }
DeleteCategoryParams contains all the bound params for the delete category operation typically these are obtained from a http.Request
swagger:parameters deleteCategory
func NewDeleteCategoryParams ¶
func NewDeleteCategoryParams() DeleteCategoryParams
NewDeleteCategoryParams creates a new DeleteCategoryParams object with the default values initialized.
func (*DeleteCategoryParams) BindRequest ¶
func (o *DeleteCategoryParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type DeleteCategoryURL ¶
type DeleteCategoryURL struct { ID int64 // contains filtered or unexported fields }
DeleteCategoryURL generates an URL for the delete category operation
func (*DeleteCategoryURL) Build ¶
func (o *DeleteCategoryURL) Build() (*url.URL, error)
Build a url path and query string
func (*DeleteCategoryURL) BuildFull ¶
func (o *DeleteCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*DeleteCategoryURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*DeleteCategoryURL) SetBasePath ¶
func (o *DeleteCategoryURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*DeleteCategoryURL) String ¶
func (o *DeleteCategoryURL) String() string
String returns the string representation of the path with query string
func (*DeleteCategoryURL) StringFull ¶
func (o *DeleteCategoryURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*DeleteCategoryURL) WithBasePath ¶
func (o *DeleteCategoryURL) WithBasePath(bp string) *DeleteCategoryURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type GetCategories ¶
type GetCategories struct { Context *middleware.Context Handler GetCategoriesHandler }
GetCategories swagger:route GET /categories Categories getCategories
Get all categories
func NewGetCategories ¶
func NewGetCategories(ctx *middleware.Context, handler GetCategoriesHandler) *GetCategories
NewGetCategories creates a new http.Handler for the get categories operation
func (*GetCategories) ServeHTTP ¶
func (o *GetCategories) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type GetCategoriesHandler ¶
type GetCategoriesHandler interface {
Handle(GetCategoriesParams) middleware.Responder
}
GetCategoriesHandler interface for that can handle valid get categories params
type GetCategoriesHandlerFunc ¶
type GetCategoriesHandlerFunc func(GetCategoriesParams) middleware.Responder
GetCategoriesHandlerFunc turns a function with the right signature into a get categories handler
func (GetCategoriesHandlerFunc) Handle ¶
func (fn GetCategoriesHandlerFunc) Handle(params GetCategoriesParams) middleware.Responder
Handle executing the request and returning a response
type GetCategoriesNotFound ¶
type GetCategoriesNotFound struct { }
GetCategoriesNotFound No items found
swagger:response getCategoriesNotFound
func NewGetCategoriesNotFound ¶
func NewGetCategoriesNotFound() *GetCategoriesNotFound
NewGetCategoriesNotFound creates GetCategoriesNotFound with default headers values
func (*GetCategoriesNotFound) WriteResponse ¶
func (o *GetCategoriesNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type GetCategoriesOK ¶
type GetCategoriesOK struct { /* In: Body */ Payload models.Categories `json:"body,omitempty"` }
GetCategoriesOK Status Ok
swagger:response getCategoriesOK
func NewGetCategoriesOK ¶
func NewGetCategoriesOK() *GetCategoriesOK
NewGetCategoriesOK creates GetCategoriesOK with default headers values
func (*GetCategoriesOK) SetPayload ¶
func (o *GetCategoriesOK) SetPayload(payload models.Categories)
SetPayload sets the payload to the get categories o k response
func (*GetCategoriesOK) WithPayload ¶
func (o *GetCategoriesOK) WithPayload(payload models.Categories) *GetCategoriesOK
WithPayload adds the payload to the get categories o k response
func (*GetCategoriesOK) WriteResponse ¶
func (o *GetCategoriesOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type GetCategoriesParams ¶
GetCategoriesParams contains all the bound params for the get categories operation typically these are obtained from a http.Request
swagger:parameters getCategories
func NewGetCategoriesParams ¶
func NewGetCategoriesParams() GetCategoriesParams
NewGetCategoriesParams creates a new GetCategoriesParams object with the default values initialized.
func (*GetCategoriesParams) BindRequest ¶
func (o *GetCategoriesParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type GetCategoriesURL ¶
type GetCategoriesURL struct {
// contains filtered or unexported fields
}
GetCategoriesURL generates an URL for the get categories operation
func (*GetCategoriesURL) Build ¶
func (o *GetCategoriesURL) Build() (*url.URL, error)
Build a url path and query string
func (*GetCategoriesURL) BuildFull ¶
func (o *GetCategoriesURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*GetCategoriesURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*GetCategoriesURL) SetBasePath ¶
func (o *GetCategoriesURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*GetCategoriesURL) String ¶
func (o *GetCategoriesURL) String() string
String returns the string representation of the path with query string
func (*GetCategoriesURL) StringFull ¶
func (o *GetCategoriesURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*GetCategoriesURL) WithBasePath ¶
func (o *GetCategoriesURL) WithBasePath(bp string) *GetCategoriesURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type GetCategory ¶
type GetCategory struct { Context *middleware.Context Handler GetCategoryHandler }
GetCategory swagger:route GET /categories/{id} Categories getCategory
Get a specific Category
func NewGetCategory ¶
func NewGetCategory(ctx *middleware.Context, handler GetCategoryHandler) *GetCategory
NewGetCategory creates a new http.Handler for the get category operation
func (*GetCategory) ServeHTTP ¶
func (o *GetCategory) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type GetCategoryBadRequest ¶
type GetCategoryBadRequest struct { }
GetCategoryBadRequest Invalid input
swagger:response getCategoryBadRequest
func NewGetCategoryBadRequest ¶
func NewGetCategoryBadRequest() *GetCategoryBadRequest
NewGetCategoryBadRequest creates GetCategoryBadRequest with default headers values
func (*GetCategoryBadRequest) WriteResponse ¶
func (o *GetCategoryBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type GetCategoryHandler ¶
type GetCategoryHandler interface {
Handle(GetCategoryParams) middleware.Responder
}
GetCategoryHandler interface for that can handle valid get category params
type GetCategoryHandlerFunc ¶
type GetCategoryHandlerFunc func(GetCategoryParams) middleware.Responder
GetCategoryHandlerFunc turns a function with the right signature into a get category handler
func (GetCategoryHandlerFunc) Handle ¶
func (fn GetCategoryHandlerFunc) Handle(params GetCategoryParams) middleware.Responder
Handle executing the request and returning a response
type GetCategoryNotFound ¶
type GetCategoryNotFound struct { }
GetCategoryNotFound No items found
swagger:response getCategoryNotFound
func NewGetCategoryNotFound ¶
func NewGetCategoryNotFound() *GetCategoryNotFound
NewGetCategoryNotFound creates GetCategoryNotFound with default headers values
func (*GetCategoryNotFound) WriteResponse ¶
func (o *GetCategoryNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type GetCategoryOK ¶
GetCategoryOK Status Ok
swagger:response getCategoryOK
func NewGetCategoryOK ¶
func NewGetCategoryOK() *GetCategoryOK
NewGetCategoryOK creates GetCategoryOK with default headers values
func (*GetCategoryOK) SetPayload ¶
func (o *GetCategoryOK) SetPayload(payload *models.Category)
SetPayload sets the payload to the get category o k response
func (*GetCategoryOK) WithPayload ¶
func (o *GetCategoryOK) WithPayload(payload *models.Category) *GetCategoryOK
WithPayload adds the payload to the get category o k response
func (*GetCategoryOK) WriteResponse ¶
func (o *GetCategoryOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type GetCategoryParams ¶
type GetCategoryParams struct { // HTTP Request Object HTTPRequest *http.Request /* Required: true In: path */ ID int64 }
GetCategoryParams contains all the bound params for the get category operation typically these are obtained from a http.Request
swagger:parameters getCategory
func NewGetCategoryParams ¶
func NewGetCategoryParams() GetCategoryParams
NewGetCategoryParams creates a new GetCategoryParams object with the default values initialized.
func (*GetCategoryParams) BindRequest ¶
func (o *GetCategoryParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type GetCategoryURL ¶
type GetCategoryURL struct { ID int64 // contains filtered or unexported fields }
GetCategoryURL generates an URL for the get category operation
func (*GetCategoryURL) Build ¶
func (o *GetCategoryURL) Build() (*url.URL, error)
Build a url path and query string
func (*GetCategoryURL) BuildFull ¶
func (o *GetCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*GetCategoryURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*GetCategoryURL) SetBasePath ¶
func (o *GetCategoryURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*GetCategoryURL) String ¶
func (o *GetCategoryURL) String() string
String returns the string representation of the path with query string
func (*GetCategoryURL) StringFull ¶
func (o *GetCategoryURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*GetCategoryURL) WithBasePath ¶
func (o *GetCategoryURL) WithBasePath(bp string) *GetCategoryURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
type UpdateCategory ¶
type UpdateCategory struct { Context *middleware.Context Handler UpdateCategoryHandler }
UpdateCategory swagger:route PUT /categories/{id} Categories updateCategory
Update a specific Category
func NewUpdateCategory ¶
func NewUpdateCategory(ctx *middleware.Context, handler UpdateCategoryHandler) *UpdateCategory
NewUpdateCategory creates a new http.Handler for the update category operation
func (*UpdateCategory) ServeHTTP ¶
func (o *UpdateCategory) ServeHTTP(rw http.ResponseWriter, r *http.Request)
type UpdateCategoryBadRequest ¶
type UpdateCategoryBadRequest struct { }
UpdateCategoryBadRequest Invalid input
swagger:response updateCategoryBadRequest
func NewUpdateCategoryBadRequest ¶
func NewUpdateCategoryBadRequest() *UpdateCategoryBadRequest
NewUpdateCategoryBadRequest creates UpdateCategoryBadRequest with default headers values
func (*UpdateCategoryBadRequest) WriteResponse ¶
func (o *UpdateCategoryBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type UpdateCategoryCreated ¶
type UpdateCategoryCreated struct { /* In: Body */ Payload *models.Category `json:"body,omitempty"` }
UpdateCategoryCreated Category Created
swagger:response updateCategoryCreated
func NewUpdateCategoryCreated ¶
func NewUpdateCategoryCreated() *UpdateCategoryCreated
NewUpdateCategoryCreated creates UpdateCategoryCreated with default headers values
func (*UpdateCategoryCreated) SetPayload ¶
func (o *UpdateCategoryCreated) SetPayload(payload *models.Category)
SetPayload sets the payload to the update category created response
func (*UpdateCategoryCreated) WithPayload ¶
func (o *UpdateCategoryCreated) WithPayload(payload *models.Category) *UpdateCategoryCreated
WithPayload adds the payload to the update category created response
func (*UpdateCategoryCreated) WriteResponse ¶
func (o *UpdateCategoryCreated) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type UpdateCategoryHandler ¶
type UpdateCategoryHandler interface {
Handle(UpdateCategoryParams) middleware.Responder
}
UpdateCategoryHandler interface for that can handle valid update category params
type UpdateCategoryHandlerFunc ¶
type UpdateCategoryHandlerFunc func(UpdateCategoryParams) middleware.Responder
UpdateCategoryHandlerFunc turns a function with the right signature into a update category handler
func (UpdateCategoryHandlerFunc) Handle ¶
func (fn UpdateCategoryHandlerFunc) Handle(params UpdateCategoryParams) middleware.Responder
Handle executing the request and returning a response
type UpdateCategoryNotFound ¶
type UpdateCategoryNotFound struct { }
UpdateCategoryNotFound No items found
swagger:response updateCategoryNotFound
func NewUpdateCategoryNotFound ¶
func NewUpdateCategoryNotFound() *UpdateCategoryNotFound
NewUpdateCategoryNotFound creates UpdateCategoryNotFound with default headers values
func (*UpdateCategoryNotFound) WriteResponse ¶
func (o *UpdateCategoryNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type UpdateCategoryParams ¶
type UpdateCategoryParams struct { // HTTP Request Object HTTPRequest *http.Request /*a category that needs to be updated Required: true In: body */ Body *models.Category /* Required: true In: path */ ID int64 }
UpdateCategoryParams contains all the bound params for the update category operation typically these are obtained from a http.Request
swagger:parameters updateCategory
func NewUpdateCategoryParams ¶
func NewUpdateCategoryParams() UpdateCategoryParams
NewUpdateCategoryParams creates a new UpdateCategoryParams object with the default values initialized.
func (*UpdateCategoryParams) BindRequest ¶
func (o *UpdateCategoryParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error
BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls
type UpdateCategoryURL ¶
type UpdateCategoryURL struct { ID int64 // contains filtered or unexported fields }
UpdateCategoryURL generates an URL for the update category operation
func (*UpdateCategoryURL) Build ¶
func (o *UpdateCategoryURL) Build() (*url.URL, error)
Build a url path and query string
func (*UpdateCategoryURL) BuildFull ¶
func (o *UpdateCategoryURL) BuildFull(scheme, host string) (*url.URL, error)
BuildFull builds a full url with scheme, host, path and query string
func (*UpdateCategoryURL) Must ¶
Must is a helper function to panic when the url builder returns an error
func (*UpdateCategoryURL) SetBasePath ¶
func (o *UpdateCategoryURL) SetBasePath(bp string)
SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
func (*UpdateCategoryURL) String ¶
func (o *UpdateCategoryURL) String() string
String returns the string representation of the path with query string
func (*UpdateCategoryURL) StringFull ¶
func (o *UpdateCategoryURL) StringFull(scheme, host string) string
StringFull returns the string representation of a complete url
func (*UpdateCategoryURL) WithBasePath ¶
func (o *UpdateCategoryURL) WithBasePath(bp string) *UpdateCategoryURL
WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string
Source Files ¶
- create_category.go
- create_category_parameters.go
- create_category_responses.go
- create_category_urlbuilder.go
- delete_categories.go
- delete_categories_parameters.go
- delete_categories_responses.go
- delete_categories_urlbuilder.go
- delete_category.go
- delete_category_parameters.go
- delete_category_responses.go
- delete_category_urlbuilder.go
- get_categories.go
- get_categories_parameters.go
- get_categories_responses.go
- get_categories_urlbuilder.go
- get_category.go
- get_category_parameters.go
- get_category_responses.go
- get_category_urlbuilder.go
- update_category.go
- update_category_parameters.go
- update_category_responses.go
- update_category_urlbuilder.go