pet

package
v0.26.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 12, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const AddPetMethodNotAllowedCode int = 405

AddPetMethodNotAllowedCode is the HTTP code returned for type AddPetMethodNotAllowed

View Source
const DeletePetBadRequestCode int = 400

DeletePetBadRequestCode is the HTTP code returned for type DeletePetBadRequest

View Source
const FindPetsByStatusBadRequestCode int = 400

FindPetsByStatusBadRequestCode is the HTTP code returned for type FindPetsByStatusBadRequest

View Source
const FindPetsByStatusOKCode int = 200

FindPetsByStatusOKCode is the HTTP code returned for type FindPetsByStatusOK

View Source
const FindPetsByTagsBadRequestCode int = 400

FindPetsByTagsBadRequestCode is the HTTP code returned for type FindPetsByTagsBadRequest

View Source
const FindPetsByTagsOKCode int = 200

FindPetsByTagsOKCode is the HTTP code returned for type FindPetsByTagsOK

View Source
const GetPetByIDBadRequestCode int = 400

GetPetByIDBadRequestCode is the HTTP code returned for type GetPetByIDBadRequest

View Source
const GetPetByIDNotFoundCode int = 404

GetPetByIDNotFoundCode is the HTTP code returned for type GetPetByIDNotFound

View Source
const GetPetByIDOKCode int = 200

GetPetByIDOKCode is the HTTP code returned for type GetPetByIDOK

View Source
const UpdatePetBadRequestCode int = 400

UpdatePetBadRequestCode is the HTTP code returned for type UpdatePetBadRequest

View Source
const UpdatePetMethodNotAllowedCode int = 405

UpdatePetMethodNotAllowedCode is the HTTP code returned for type UpdatePetMethodNotAllowed

View Source
const UpdatePetNotFoundCode int = 404

UpdatePetNotFoundCode is the HTTP code returned for type UpdatePetNotFound

View Source
const UpdatePetWithFormMethodNotAllowedCode int = 405

UpdatePetWithFormMethodNotAllowedCode is the HTTP code returned for type UpdatePetWithFormMethodNotAllowed

Variables

This section is empty.

Functions

This section is empty.

Types

type AddPet

type AddPet struct {
	Context *middleware.Context
	Handler AddPetHandler
}

AddPet swagger:route POST /pets pet addPet

Add a new pet to the store

func NewAddPet

func NewAddPet(ctx *middleware.Context, handler AddPetHandler) *AddPet

NewAddPet creates a new http.Handler for the add pet operation

func (*AddPet) ServeHTTP

func (o *AddPet) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type AddPetHandler

type AddPetHandler interface {
	Handle(AddPetParams, interface{}) middleware.Responder
}

AddPetHandler interface for that can handle valid add pet params

type AddPetHandlerFunc

type AddPetHandlerFunc func(AddPetParams, interface{}) middleware.Responder

AddPetHandlerFunc turns a function with the right signature into a add pet handler

func (AddPetHandlerFunc) Handle

func (fn AddPetHandlerFunc) Handle(params AddPetParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type AddPetMethodNotAllowed

type AddPetMethodNotAllowed struct {
}

AddPetMethodNotAllowed Invalid input

swagger:response addPetMethodNotAllowed

func NewAddPetMethodNotAllowed added in v0.2.0

func NewAddPetMethodNotAllowed() *AddPetMethodNotAllowed

NewAddPetMethodNotAllowed creates AddPetMethodNotAllowed with default headers values

func (*AddPetMethodNotAllowed) WriteResponse

func (o *AddPetMethodNotAllowed) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type AddPetParams

type AddPetParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Pet object that needs to be added to the store
	  In: body
	*/
	Body *models.Pet
}

AddPetParams contains all the bound params for the add pet operation typically these are obtained from a http.Request

swagger:parameters addPet

func NewAddPetParams added in v0.2.0

func NewAddPetParams() AddPetParams

NewAddPetParams creates a new AddPetParams object no default values defined in spec.

func (*AddPetParams) BindRequest

func (o *AddPetParams) 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.

To ensure default values, the struct must have been initialized with NewAddPetParams() beforehand.

type AddPetURL added in v0.17.0

type AddPetURL struct {
	// contains filtered or unexported fields
}

AddPetURL generates an URL for the add pet operation

func (*AddPetURL) Build added in v0.17.0

func (o *AddPetURL) Build() (*url.URL, error)

Build a url path and query string

func (*AddPetURL) BuildFull added in v0.17.0

func (o *AddPetURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*AddPetURL) Must added in v0.17.0

func (o *AddPetURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*AddPetURL) SetBasePath added in v0.17.0

func (o *AddPetURL) 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 (*AddPetURL) String added in v0.17.0

func (o *AddPetURL) String() string

String returns the string representation of the path with query string

func (*AddPetURL) StringFull added in v0.17.0

func (o *AddPetURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*AddPetURL) WithBasePath added in v0.17.0

func (o *AddPetURL) WithBasePath(bp string) *AddPetURL

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 DeletePet

type DeletePet struct {
	Context *middleware.Context
	Handler DeletePetHandler
}

DeletePet swagger:route DELETE /pets/{petId} pet deletePet

Deletes a pet

func NewDeletePet

func NewDeletePet(ctx *middleware.Context, handler DeletePetHandler) *DeletePet

NewDeletePet creates a new http.Handler for the delete pet operation

func (*DeletePet) ServeHTTP

func (o *DeletePet) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type DeletePetBadRequest

type DeletePetBadRequest struct {
}

DeletePetBadRequest Invalid pet value

swagger:response deletePetBadRequest

func NewDeletePetBadRequest added in v0.2.0

func NewDeletePetBadRequest() *DeletePetBadRequest

NewDeletePetBadRequest creates DeletePetBadRequest with default headers values

func (*DeletePetBadRequest) WriteResponse

func (o *DeletePetBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type DeletePetHandler

type DeletePetHandler interface {
	Handle(DeletePetParams, interface{}) middleware.Responder
}

DeletePetHandler interface for that can handle valid delete pet params

type DeletePetHandlerFunc

type DeletePetHandlerFunc func(DeletePetParams, interface{}) middleware.Responder

DeletePetHandlerFunc turns a function with the right signature into a delete pet handler

func (DeletePetHandlerFunc) Handle

func (fn DeletePetHandlerFunc) Handle(params DeletePetParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type DeletePetParams

type DeletePetParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*
	  Required: true
	  In: header
	*/
	APIKey string
	/*Pet id to delete
	  Required: true
	  In: path
	*/
	PetID int64
}

DeletePetParams contains all the bound params for the delete pet operation typically these are obtained from a http.Request

swagger:parameters deletePet

func NewDeletePetParams added in v0.2.0

func NewDeletePetParams() DeletePetParams

NewDeletePetParams creates a new DeletePetParams object no default values defined in spec.

func (*DeletePetParams) BindRequest

func (o *DeletePetParams) 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.

To ensure default values, the struct must have been initialized with NewDeletePetParams() beforehand.

type DeletePetURL added in v0.17.0

type DeletePetURL struct {
	PetID int64
	// contains filtered or unexported fields
}

DeletePetURL generates an URL for the delete pet operation

func (*DeletePetURL) Build added in v0.17.0

func (o *DeletePetURL) Build() (*url.URL, error)

Build a url path and query string

func (*DeletePetURL) BuildFull added in v0.17.0

func (o *DeletePetURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*DeletePetURL) Must added in v0.17.0

func (o *DeletePetURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*DeletePetURL) SetBasePath added in v0.17.0

func (o *DeletePetURL) 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 (*DeletePetURL) String added in v0.17.0

func (o *DeletePetURL) String() string

String returns the string representation of the path with query string

func (*DeletePetURL) StringFull added in v0.17.0

func (o *DeletePetURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*DeletePetURL) WithBasePath added in v0.17.0

func (o *DeletePetURL) WithBasePath(bp string) *DeletePetURL

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 FindPetsByStatus

type FindPetsByStatus struct {
	Context *middleware.Context
	Handler FindPetsByStatusHandler
}

FindPetsByStatus swagger:route GET /pets/findByStatus pet findPetsByStatus

Finds Pets by status

Multiple status values can be provided with comma separated strings

func NewFindPetsByStatus

func NewFindPetsByStatus(ctx *middleware.Context, handler FindPetsByStatusHandler) *FindPetsByStatus

NewFindPetsByStatus creates a new http.Handler for the find pets by status operation

func (*FindPetsByStatus) ServeHTTP

func (o *FindPetsByStatus) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type FindPetsByStatusBadRequest

type FindPetsByStatusBadRequest struct {
}

FindPetsByStatusBadRequest Invalid status value

swagger:response findPetsByStatusBadRequest

func NewFindPetsByStatusBadRequest added in v0.2.0

func NewFindPetsByStatusBadRequest() *FindPetsByStatusBadRequest

NewFindPetsByStatusBadRequest creates FindPetsByStatusBadRequest with default headers values

func (*FindPetsByStatusBadRequest) WriteResponse

func (o *FindPetsByStatusBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type FindPetsByStatusHandler

type FindPetsByStatusHandler interface {
	Handle(FindPetsByStatusParams, interface{}) middleware.Responder
}

FindPetsByStatusHandler interface for that can handle valid find pets by status params

type FindPetsByStatusHandlerFunc

type FindPetsByStatusHandlerFunc func(FindPetsByStatusParams, interface{}) middleware.Responder

FindPetsByStatusHandlerFunc turns a function with the right signature into a find pets by status handler

func (FindPetsByStatusHandlerFunc) Handle

func (fn FindPetsByStatusHandlerFunc) Handle(params FindPetsByStatusParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type FindPetsByStatusOK

type FindPetsByStatusOK struct {

	/*
	  In: Body
	*/
	Payload []*models.Pet `json:"body,omitempty"`
}

FindPetsByStatusOK successful operation

swagger:response findPetsByStatusOK

func NewFindPetsByStatusOK added in v0.2.0

func NewFindPetsByStatusOK() *FindPetsByStatusOK

NewFindPetsByStatusOK creates FindPetsByStatusOK with default headers values

func (*FindPetsByStatusOK) SetPayload added in v0.17.0

func (o *FindPetsByStatusOK) SetPayload(payload []*models.Pet)

SetPayload sets the payload to the find pets by status o k response

func (*FindPetsByStatusOK) WithPayload added in v0.2.0

func (o *FindPetsByStatusOK) WithPayload(payload []*models.Pet) *FindPetsByStatusOK

WithPayload adds the payload to the find pets by status o k response

func (*FindPetsByStatusOK) WriteResponse

func (o *FindPetsByStatusOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type FindPetsByStatusParams

type FindPetsByStatusParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Status values that need to be considered for filter
	  In: query
	  Collection Format: multi
	*/
	Status []string
}

FindPetsByStatusParams contains all the bound params for the find pets by status operation typically these are obtained from a http.Request

swagger:parameters findPetsByStatus

func NewFindPetsByStatusParams added in v0.2.0

func NewFindPetsByStatusParams() FindPetsByStatusParams

NewFindPetsByStatusParams creates a new FindPetsByStatusParams object no default values defined in spec.

func (*FindPetsByStatusParams) BindRequest

func (o *FindPetsByStatusParams) 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.

To ensure default values, the struct must have been initialized with NewFindPetsByStatusParams() beforehand.

type FindPetsByStatusURL added in v0.17.0

type FindPetsByStatusURL struct {
	Status []string
	// contains filtered or unexported fields
}

FindPetsByStatusURL generates an URL for the find pets by status operation

func (*FindPetsByStatusURL) Build added in v0.17.0

func (o *FindPetsByStatusURL) Build() (*url.URL, error)

Build a url path and query string

func (*FindPetsByStatusURL) BuildFull added in v0.17.0

func (o *FindPetsByStatusURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*FindPetsByStatusURL) Must added in v0.17.0

func (o *FindPetsByStatusURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*FindPetsByStatusURL) SetBasePath added in v0.17.0

func (o *FindPetsByStatusURL) 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 (*FindPetsByStatusURL) String added in v0.17.0

func (o *FindPetsByStatusURL) String() string

String returns the string representation of the path with query string

func (*FindPetsByStatusURL) StringFull added in v0.17.0

func (o *FindPetsByStatusURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*FindPetsByStatusURL) WithBasePath added in v0.17.0

func (o *FindPetsByStatusURL) WithBasePath(bp string) *FindPetsByStatusURL

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 FindPetsByTags

type FindPetsByTags struct {
	Context *middleware.Context
	Handler FindPetsByTagsHandler
}

FindPetsByTags swagger:route GET /pets/findByTags pet findPetsByTags

Finds Pets by tags

Muliple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.

func NewFindPetsByTags

func NewFindPetsByTags(ctx *middleware.Context, handler FindPetsByTagsHandler) *FindPetsByTags

NewFindPetsByTags creates a new http.Handler for the find pets by tags operation

func (*FindPetsByTags) ServeHTTP

func (o *FindPetsByTags) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type FindPetsByTagsBadRequest

type FindPetsByTagsBadRequest struct {
}

FindPetsByTagsBadRequest Invalid tag value

swagger:response findPetsByTagsBadRequest

func NewFindPetsByTagsBadRequest added in v0.2.0

func NewFindPetsByTagsBadRequest() *FindPetsByTagsBadRequest

NewFindPetsByTagsBadRequest creates FindPetsByTagsBadRequest with default headers values

func (*FindPetsByTagsBadRequest) WriteResponse

func (o *FindPetsByTagsBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type FindPetsByTagsHandler

type FindPetsByTagsHandler interface {
	Handle(FindPetsByTagsParams, interface{}) middleware.Responder
}

FindPetsByTagsHandler interface for that can handle valid find pets by tags params

type FindPetsByTagsHandlerFunc

type FindPetsByTagsHandlerFunc func(FindPetsByTagsParams, interface{}) middleware.Responder

FindPetsByTagsHandlerFunc turns a function with the right signature into a find pets by tags handler

func (FindPetsByTagsHandlerFunc) Handle

func (fn FindPetsByTagsHandlerFunc) Handle(params FindPetsByTagsParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type FindPetsByTagsOK

type FindPetsByTagsOK struct {

	/*
	  In: Body
	*/
	Payload []*models.Pet `json:"body,omitempty"`
}

FindPetsByTagsOK successful operation

swagger:response findPetsByTagsOK

func NewFindPetsByTagsOK added in v0.2.0

func NewFindPetsByTagsOK() *FindPetsByTagsOK

NewFindPetsByTagsOK creates FindPetsByTagsOK with default headers values

func (*FindPetsByTagsOK) SetPayload added in v0.17.0

func (o *FindPetsByTagsOK) SetPayload(payload []*models.Pet)

SetPayload sets the payload to the find pets by tags o k response

func (*FindPetsByTagsOK) WithPayload added in v0.2.0

func (o *FindPetsByTagsOK) WithPayload(payload []*models.Pet) *FindPetsByTagsOK

WithPayload adds the payload to the find pets by tags o k response

func (*FindPetsByTagsOK) WriteResponse

func (o *FindPetsByTagsOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type FindPetsByTagsParams

type FindPetsByTagsParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Tags to filter by
	  In: query
	  Collection Format: multi
	*/
	Tags []string
}

FindPetsByTagsParams contains all the bound params for the find pets by tags operation typically these are obtained from a http.Request

swagger:parameters findPetsByTags

func NewFindPetsByTagsParams added in v0.2.0

func NewFindPetsByTagsParams() FindPetsByTagsParams

NewFindPetsByTagsParams creates a new FindPetsByTagsParams object no default values defined in spec.

func (*FindPetsByTagsParams) BindRequest

func (o *FindPetsByTagsParams) 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.

To ensure default values, the struct must have been initialized with NewFindPetsByTagsParams() beforehand.

type FindPetsByTagsURL added in v0.17.0

type FindPetsByTagsURL struct {
	Tags []string
	// contains filtered or unexported fields
}

FindPetsByTagsURL generates an URL for the find pets by tags operation

func (*FindPetsByTagsURL) Build added in v0.17.0

func (o *FindPetsByTagsURL) Build() (*url.URL, error)

Build a url path and query string

func (*FindPetsByTagsURL) BuildFull added in v0.17.0

func (o *FindPetsByTagsURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*FindPetsByTagsURL) Must added in v0.17.0

func (o *FindPetsByTagsURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*FindPetsByTagsURL) SetBasePath added in v0.17.0

func (o *FindPetsByTagsURL) 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 (*FindPetsByTagsURL) String added in v0.17.0

func (o *FindPetsByTagsURL) String() string

String returns the string representation of the path with query string

func (*FindPetsByTagsURL) StringFull added in v0.17.0

func (o *FindPetsByTagsURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*FindPetsByTagsURL) WithBasePath added in v0.17.0

func (o *FindPetsByTagsURL) WithBasePath(bp string) *FindPetsByTagsURL

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 GetPetByID

type GetPetByID struct {
	Context *middleware.Context
	Handler GetPetByIDHandler
}

GetPetByID swagger:route GET /pets/{petId} pet getPetById

Find pet by ID

Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions

func NewGetPetByID

func NewGetPetByID(ctx *middleware.Context, handler GetPetByIDHandler) *GetPetByID

NewGetPetByID creates a new http.Handler for the get pet by Id operation

func (*GetPetByID) ServeHTTP

func (o *GetPetByID) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type GetPetByIDBadRequest

type GetPetByIDBadRequest struct {
}

GetPetByIDBadRequest Invalid ID supplied

swagger:response getPetByIdBadRequest

func NewGetPetByIDBadRequest added in v0.2.0

func NewGetPetByIDBadRequest() *GetPetByIDBadRequest

NewGetPetByIDBadRequest creates GetPetByIDBadRequest with default headers values

func (*GetPetByIDBadRequest) WriteResponse

func (o *GetPetByIDBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetPetByIDHandler

type GetPetByIDHandler interface {
	Handle(GetPetByIDParams, interface{}) middleware.Responder
}

GetPetByIDHandler interface for that can handle valid get pet by Id params

type GetPetByIDHandlerFunc

type GetPetByIDHandlerFunc func(GetPetByIDParams, interface{}) middleware.Responder

GetPetByIDHandlerFunc turns a function with the right signature into a get pet by Id handler

func (GetPetByIDHandlerFunc) Handle

func (fn GetPetByIDHandlerFunc) Handle(params GetPetByIDParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type GetPetByIDNotFound

type GetPetByIDNotFound struct {
}

GetPetByIDNotFound Pet not found

swagger:response getPetByIdNotFound

func NewGetPetByIDNotFound added in v0.2.0

func NewGetPetByIDNotFound() *GetPetByIDNotFound

NewGetPetByIDNotFound creates GetPetByIDNotFound with default headers values

func (*GetPetByIDNotFound) WriteResponse

func (o *GetPetByIDNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetPetByIDOK

type GetPetByIDOK struct {

	/*
	  In: Body
	*/
	Payload *models.Pet `json:"body,omitempty"`
}

GetPetByIDOK successful operation

swagger:response getPetByIdOK

func NewGetPetByIDOK added in v0.2.0

func NewGetPetByIDOK() *GetPetByIDOK

NewGetPetByIDOK creates GetPetByIDOK with default headers values

func (*GetPetByIDOK) SetPayload added in v0.17.0

func (o *GetPetByIDOK) SetPayload(payload *models.Pet)

SetPayload sets the payload to the get pet by Id o k response

func (*GetPetByIDOK) WithPayload added in v0.2.0

func (o *GetPetByIDOK) WithPayload(payload *models.Pet) *GetPetByIDOK

WithPayload adds the payload to the get pet by Id o k response

func (*GetPetByIDOK) WriteResponse

func (o *GetPetByIDOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetPetByIDParams

type GetPetByIDParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*ID of pet that needs to be fetched
	  Required: true
	  In: path
	*/
	PetID int64
}

GetPetByIDParams contains all the bound params for the get pet by Id operation typically these are obtained from a http.Request

swagger:parameters getPetById

func NewGetPetByIDParams added in v0.2.0

func NewGetPetByIDParams() GetPetByIDParams

NewGetPetByIDParams creates a new GetPetByIDParams object no default values defined in spec.

func (*GetPetByIDParams) BindRequest

func (o *GetPetByIDParams) 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.

To ensure default values, the struct must have been initialized with NewGetPetByIDParams() beforehand.

type GetPetByIDURL added in v0.17.0

type GetPetByIDURL struct {
	PetID int64
	// contains filtered or unexported fields
}

GetPetByIDURL generates an URL for the get pet by Id operation

func (*GetPetByIDURL) Build added in v0.17.0

func (o *GetPetByIDURL) Build() (*url.URL, error)

Build a url path and query string

func (*GetPetByIDURL) BuildFull added in v0.17.0

func (o *GetPetByIDURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*GetPetByIDURL) Must added in v0.17.0

func (o *GetPetByIDURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*GetPetByIDURL) SetBasePath added in v0.17.0

func (o *GetPetByIDURL) 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 (*GetPetByIDURL) String added in v0.17.0

func (o *GetPetByIDURL) String() string

String returns the string representation of the path with query string

func (*GetPetByIDURL) StringFull added in v0.17.0

func (o *GetPetByIDURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*GetPetByIDURL) WithBasePath added in v0.17.0

func (o *GetPetByIDURL) WithBasePath(bp string) *GetPetByIDURL

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 UpdatePet

type UpdatePet struct {
	Context *middleware.Context
	Handler UpdatePetHandler
}

UpdatePet swagger:route PUT /pets pet updatePet

Update an existing pet

func NewUpdatePet

func NewUpdatePet(ctx *middleware.Context, handler UpdatePetHandler) *UpdatePet

NewUpdatePet creates a new http.Handler for the update pet operation

func (*UpdatePet) ServeHTTP

func (o *UpdatePet) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type UpdatePetBadRequest

type UpdatePetBadRequest struct {
}

UpdatePetBadRequest Invalid ID supplied

swagger:response updatePetBadRequest

func NewUpdatePetBadRequest added in v0.2.0

func NewUpdatePetBadRequest() *UpdatePetBadRequest

NewUpdatePetBadRequest creates UpdatePetBadRequest with default headers values

func (*UpdatePetBadRequest) WriteResponse

func (o *UpdatePetBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UpdatePetHandler

type UpdatePetHandler interface {
	Handle(UpdatePetParams, interface{}) middleware.Responder
}

UpdatePetHandler interface for that can handle valid update pet params

type UpdatePetHandlerFunc

type UpdatePetHandlerFunc func(UpdatePetParams, interface{}) middleware.Responder

UpdatePetHandlerFunc turns a function with the right signature into a update pet handler

func (UpdatePetHandlerFunc) Handle

func (fn UpdatePetHandlerFunc) Handle(params UpdatePetParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type UpdatePetMethodNotAllowed

type UpdatePetMethodNotAllowed struct {
}

UpdatePetMethodNotAllowed Validation exception

swagger:response updatePetMethodNotAllowed

func NewUpdatePetMethodNotAllowed added in v0.2.0

func NewUpdatePetMethodNotAllowed() *UpdatePetMethodNotAllowed

NewUpdatePetMethodNotAllowed creates UpdatePetMethodNotAllowed with default headers values

func (*UpdatePetMethodNotAllowed) WriteResponse

func (o *UpdatePetMethodNotAllowed) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UpdatePetNotFound

type UpdatePetNotFound struct {
}

UpdatePetNotFound Pet not found

swagger:response updatePetNotFound

func NewUpdatePetNotFound added in v0.2.0

func NewUpdatePetNotFound() *UpdatePetNotFound

NewUpdatePetNotFound creates UpdatePetNotFound with default headers values

func (*UpdatePetNotFound) WriteResponse

func (o *UpdatePetNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UpdatePetParams

type UpdatePetParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Pet object that needs to be added to the store
	  In: body
	*/
	Body *models.Pet
}

UpdatePetParams contains all the bound params for the update pet operation typically these are obtained from a http.Request

swagger:parameters updatePet

func NewUpdatePetParams added in v0.2.0

func NewUpdatePetParams() UpdatePetParams

NewUpdatePetParams creates a new UpdatePetParams object no default values defined in spec.

func (*UpdatePetParams) BindRequest

func (o *UpdatePetParams) 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.

To ensure default values, the struct must have been initialized with NewUpdatePetParams() beforehand.

type UpdatePetURL added in v0.17.0

type UpdatePetURL struct {
	// contains filtered or unexported fields
}

UpdatePetURL generates an URL for the update pet operation

func (*UpdatePetURL) Build added in v0.17.0

func (o *UpdatePetURL) Build() (*url.URL, error)

Build a url path and query string

func (*UpdatePetURL) BuildFull added in v0.17.0

func (o *UpdatePetURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*UpdatePetURL) Must added in v0.17.0

func (o *UpdatePetURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*UpdatePetURL) SetBasePath added in v0.17.0

func (o *UpdatePetURL) 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 (*UpdatePetURL) String added in v0.17.0

func (o *UpdatePetURL) String() string

String returns the string representation of the path with query string

func (*UpdatePetURL) StringFull added in v0.17.0

func (o *UpdatePetURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*UpdatePetURL) WithBasePath added in v0.17.0

func (o *UpdatePetURL) WithBasePath(bp string) *UpdatePetURL

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 UpdatePetWithForm

type UpdatePetWithForm struct {
	Context *middleware.Context
	Handler UpdatePetWithFormHandler
}

UpdatePetWithForm swagger:route POST /pets/{petId} pet updatePetWithForm

Updates a pet in the store with form data

func NewUpdatePetWithForm

func NewUpdatePetWithForm(ctx *middleware.Context, handler UpdatePetWithFormHandler) *UpdatePetWithForm

NewUpdatePetWithForm creates a new http.Handler for the update pet with form operation

func (*UpdatePetWithForm) ServeHTTP

func (o *UpdatePetWithForm) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type UpdatePetWithFormHandler

type UpdatePetWithFormHandler interface {
	Handle(UpdatePetWithFormParams, interface{}) middleware.Responder
}

UpdatePetWithFormHandler interface for that can handle valid update pet with form params

type UpdatePetWithFormHandlerFunc

type UpdatePetWithFormHandlerFunc func(UpdatePetWithFormParams, interface{}) middleware.Responder

UpdatePetWithFormHandlerFunc turns a function with the right signature into a update pet with form handler

func (UpdatePetWithFormHandlerFunc) Handle

func (fn UpdatePetWithFormHandlerFunc) Handle(params UpdatePetWithFormParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type UpdatePetWithFormMethodNotAllowed

type UpdatePetWithFormMethodNotAllowed struct {
}

UpdatePetWithFormMethodNotAllowed Invalid input

swagger:response updatePetWithFormMethodNotAllowed

func NewUpdatePetWithFormMethodNotAllowed added in v0.2.0

func NewUpdatePetWithFormMethodNotAllowed() *UpdatePetWithFormMethodNotAllowed

NewUpdatePetWithFormMethodNotAllowed creates UpdatePetWithFormMethodNotAllowed with default headers values

func (*UpdatePetWithFormMethodNotAllowed) WriteResponse

func (o *UpdatePetWithFormMethodNotAllowed) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type UpdatePetWithFormParams

type UpdatePetWithFormParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Updated name of the pet
	  Required: true
	  In: formData
	*/
	Name string
	/*ID of pet that needs to be updated
	  Required: true
	  In: path
	*/
	PetID string
	/*Updated status of the pet
	  Required: true
	  In: formData
	*/
	Status string
}

UpdatePetWithFormParams contains all the bound params for the update pet with form operation typically these are obtained from a http.Request

swagger:parameters updatePetWithForm

func NewUpdatePetWithFormParams added in v0.2.0

func NewUpdatePetWithFormParams() UpdatePetWithFormParams

NewUpdatePetWithFormParams creates a new UpdatePetWithFormParams object no default values defined in spec.

func (*UpdatePetWithFormParams) BindRequest

func (o *UpdatePetWithFormParams) 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.

To ensure default values, the struct must have been initialized with NewUpdatePetWithFormParams() beforehand.

type UpdatePetWithFormURL added in v0.17.0

type UpdatePetWithFormURL struct {
	PetID string
	// contains filtered or unexported fields
}

UpdatePetWithFormURL generates an URL for the update pet with form operation

func (*UpdatePetWithFormURL) Build added in v0.17.0

func (o *UpdatePetWithFormURL) Build() (*url.URL, error)

Build a url path and query string

func (*UpdatePetWithFormURL) BuildFull added in v0.17.0

func (o *UpdatePetWithFormURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*UpdatePetWithFormURL) Must added in v0.17.0

func (o *UpdatePetWithFormURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*UpdatePetWithFormURL) SetBasePath added in v0.17.0

func (o *UpdatePetWithFormURL) 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 (*UpdatePetWithFormURL) String added in v0.17.0

func (o *UpdatePetWithFormURL) String() string

String returns the string representation of the path with query string

func (*UpdatePetWithFormURL) StringFull added in v0.17.0

func (o *UpdatePetWithFormURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*UpdatePetWithFormURL) WithBasePath added in v0.17.0

func (o *UpdatePetWithFormURL) WithBasePath(bp string) *UpdatePetWithFormURL

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL