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: 15 Imported by: 0

Documentation

Index

Constants

View Source
const PetCreateCreatedCode int = 201

PetCreateCreatedCode is the HTTP code returned for type PetCreateCreated

View Source
const PetCreateMethodNotAllowedCode int = 405

PetCreateMethodNotAllowedCode is the HTTP code returned for type PetCreateMethodNotAllowed

View Source
const PetDeleteBadRequestCode int = 400

PetDeleteBadRequestCode is the HTTP code returned for type PetDeleteBadRequest

View Source
const PetDeleteNoContentCode int = 204

PetDeleteNoContentCode is the HTTP code returned for type PetDeleteNoContent

View Source
const PetDeleteNotFoundCode int = 404

PetDeleteNotFoundCode is the HTTP code returned for type PetDeleteNotFound

View Source
const PetGetBadRequestCode int = 400

PetGetBadRequestCode is the HTTP code returned for type PetGetBadRequest

View Source
const PetGetNotFoundCode int = 404

PetGetNotFoundCode is the HTTP code returned for type PetGetNotFound

View Source
const PetGetOKCode int = 200

PetGetOKCode is the HTTP code returned for type PetGetOK

View Source
const PetListBadRequestCode int = 400

PetListBadRequestCode is the HTTP code returned for type PetListBadRequest

View Source
const PetListOKCode int = 200

PetListOKCode is the HTTP code returned for type PetListOK

View Source
const PetUpdateBadRequestCode int = 400

PetUpdateBadRequestCode is the HTTP code returned for type PetUpdateBadRequest

View Source
const PetUpdateCreatedCode int = 201

PetUpdateCreatedCode is the HTTP code returned for type PetUpdateCreated

View Source
const PetUpdateMethodNotAllowedCode int = 405

PetUpdateMethodNotAllowedCode is the HTTP code returned for type PetUpdateMethodNotAllowed

View Source
const PetUpdateNotFoundCode int = 404

PetUpdateNotFoundCode is the HTTP code returned for type PetUpdateNotFound

View Source
const PetUploadImageOKCode int = 200

PetUploadImageOKCode is the HTTP code returned for type PetUploadImageOK

Variables

This section is empty.

Functions

This section is empty.

Types

type PetCreate

type PetCreate struct {
	Context *middleware.Context
	Handler PetCreateHandler
}

PetCreate swagger:route POST /pet pet petCreate

Add a new pet to the store

func NewPetCreate

func NewPetCreate(ctx *middleware.Context, handler PetCreateHandler) *PetCreate

NewPetCreate creates a new http.Handler for the pet create operation

func (*PetCreate) ServeHTTP

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

type PetCreateCreated

type PetCreateCreated struct {

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

PetCreateCreated Created

swagger:response petCreateCreated

func NewPetCreateCreated

func NewPetCreateCreated() *PetCreateCreated

NewPetCreateCreated creates PetCreateCreated with default headers values

func (*PetCreateCreated) SetPayload

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

SetPayload sets the payload to the pet create created response

func (*PetCreateCreated) WithPayload

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

WithPayload adds the payload to the pet create created response

func (*PetCreateCreated) WriteResponse

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

WriteResponse to the client

type PetCreateHandler

type PetCreateHandler interface {
	Handle(PetCreateParams, interface{}) middleware.Responder
}

PetCreateHandler interface for that can handle valid pet create params

type PetCreateHandlerFunc

type PetCreateHandlerFunc func(PetCreateParams, interface{}) middleware.Responder

PetCreateHandlerFunc turns a function with the right signature into a pet create handler

func (PetCreateHandlerFunc) Handle

func (fn PetCreateHandlerFunc) Handle(params PetCreateParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetCreateMethodNotAllowed

type PetCreateMethodNotAllowed struct {
}

PetCreateMethodNotAllowed Invalid input

swagger:response petCreateMethodNotAllowed

func NewPetCreateMethodNotAllowed

func NewPetCreateMethodNotAllowed() *PetCreateMethodNotAllowed

NewPetCreateMethodNotAllowed creates PetCreateMethodNotAllowed with default headers values

func (*PetCreateMethodNotAllowed) WriteResponse

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

WriteResponse to the client

type PetCreateParams

type PetCreateParams struct {

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

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

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

swagger:parameters PetCreate

func NewPetCreateParams

func NewPetCreateParams() PetCreateParams

NewPetCreateParams creates a new PetCreateParams object no default values defined in spec.

func (*PetCreateParams) BindRequest

func (o *PetCreateParams) 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 NewPetCreateParams() beforehand.

type PetCreateURL

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

PetCreateURL generates an URL for the pet create operation

func (*PetCreateURL) Build

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

Build a url path and query string

func (*PetCreateURL) BuildFull

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

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

func (*PetCreateURL) Must

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

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

func (*PetCreateURL) SetBasePath

func (o *PetCreateURL) 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 (*PetCreateURL) String

func (o *PetCreateURL) String() string

String returns the string representation of the path with query string

func (*PetCreateURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetCreateURL) WithBasePath

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

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 PetDelete

type PetDelete struct {
	Context *middleware.Context
	Handler PetDeleteHandler
}

PetDelete swagger:route DELETE /pet/{petId} pet petDelete

Deletes a pet

func NewPetDelete

func NewPetDelete(ctx *middleware.Context, handler PetDeleteHandler) *PetDelete

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

func (*PetDelete) ServeHTTP

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

type PetDeleteBadRequest

type PetDeleteBadRequest struct {
}

PetDeleteBadRequest Invalid ID supplied

swagger:response petDeleteBadRequest

func NewPetDeleteBadRequest

func NewPetDeleteBadRequest() *PetDeleteBadRequest

NewPetDeleteBadRequest creates PetDeleteBadRequest with default headers values

func (*PetDeleteBadRequest) WriteResponse

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

WriteResponse to the client

type PetDeleteHandler

type PetDeleteHandler interface {
	Handle(PetDeleteParams, interface{}) middleware.Responder
}

PetDeleteHandler interface for that can handle valid pet delete params

type PetDeleteHandlerFunc

type PetDeleteHandlerFunc func(PetDeleteParams, interface{}) middleware.Responder

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

func (PetDeleteHandlerFunc) Handle

func (fn PetDeleteHandlerFunc) Handle(params PetDeleteParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetDeleteNoContent

type PetDeleteNoContent struct {
}

PetDeleteNoContent Deleted successfully

swagger:response petDeleteNoContent

func NewPetDeleteNoContent

func NewPetDeleteNoContent() *PetDeleteNoContent

NewPetDeleteNoContent creates PetDeleteNoContent with default headers values

func (*PetDeleteNoContent) WriteResponse

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

WriteResponse to the client

type PetDeleteNotFound

type PetDeleteNotFound struct {
}

PetDeleteNotFound Pet not found

swagger:response petDeleteNotFound

func NewPetDeleteNotFound

func NewPetDeleteNotFound() *PetDeleteNotFound

NewPetDeleteNotFound creates PetDeleteNotFound with default headers values

func (*PetDeleteNotFound) WriteResponse

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

WriteResponse to the client

type PetDeleteParams

type PetDeleteParams struct {

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

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

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

swagger:parameters PetDelete

func NewPetDeleteParams

func NewPetDeleteParams() PetDeleteParams

NewPetDeleteParams creates a new PetDeleteParams object no default values defined in spec.

func (*PetDeleteParams) BindRequest

func (o *PetDeleteParams) 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 NewPetDeleteParams() beforehand.

type PetDeleteURL

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

PetDeleteURL generates an URL for the pet delete operation

func (*PetDeleteURL) Build

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

Build a url path and query string

func (*PetDeleteURL) BuildFull

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

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

func (*PetDeleteURL) Must

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

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

func (*PetDeleteURL) SetBasePath

func (o *PetDeleteURL) 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 (*PetDeleteURL) String

func (o *PetDeleteURL) String() string

String returns the string representation of the path with query string

func (*PetDeleteURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetDeleteURL) WithBasePath

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

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 PetGet

type PetGet struct {
	Context *middleware.Context
	Handler PetGetHandler
}

PetGet swagger:route GET /pet/{petId} pet petGet

Get pet by it's ID

func NewPetGet

func NewPetGet(ctx *middleware.Context, handler PetGetHandler) *PetGet

NewPetGet creates a new http.Handler for the pet get operation

func (*PetGet) ServeHTTP

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

type PetGetBadRequest

type PetGetBadRequest struct {
}

PetGetBadRequest Invalid ID supplied

swagger:response petGetBadRequest

func NewPetGetBadRequest

func NewPetGetBadRequest() *PetGetBadRequest

NewPetGetBadRequest creates PetGetBadRequest with default headers values

func (*PetGetBadRequest) WriteResponse

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

WriteResponse to the client

type PetGetHandler

type PetGetHandler interface {
	Handle(PetGetParams, interface{}) middleware.Responder
}

PetGetHandler interface for that can handle valid pet get params

type PetGetHandlerFunc

type PetGetHandlerFunc func(PetGetParams, interface{}) middleware.Responder

PetGetHandlerFunc turns a function with the right signature into a pet get handler

func (PetGetHandlerFunc) Handle

func (fn PetGetHandlerFunc) Handle(params PetGetParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetGetNotFound

type PetGetNotFound struct {
}

PetGetNotFound Pet not found

swagger:response petGetNotFound

func NewPetGetNotFound

func NewPetGetNotFound() *PetGetNotFound

NewPetGetNotFound creates PetGetNotFound with default headers values

func (*PetGetNotFound) WriteResponse

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

WriteResponse to the client

type PetGetOK

type PetGetOK struct {

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

PetGetOK successful operation

swagger:response petGetOK

func NewPetGetOK

func NewPetGetOK() *PetGetOK

NewPetGetOK creates PetGetOK with default headers values

func (*PetGetOK) SetPayload

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

SetPayload sets the payload to the pet get o k response

func (*PetGetOK) WithPayload

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

WithPayload adds the payload to the pet get o k response

func (*PetGetOK) WriteResponse

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

WriteResponse to the client

type PetGetParams

type PetGetParams struct {

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

	/*ID of pet to return
	  Required: true
	  In: path
	*/
	PetID int64
}

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

swagger:parameters PetGet

func NewPetGetParams

func NewPetGetParams() PetGetParams

NewPetGetParams creates a new PetGetParams object no default values defined in spec.

func (*PetGetParams) BindRequest

func (o *PetGetParams) 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 NewPetGetParams() beforehand.

type PetGetURL

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

PetGetURL generates an URL for the pet get operation

func (*PetGetURL) Build

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

Build a url path and query string

func (*PetGetURL) BuildFull

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

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

func (*PetGetURL) Must

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

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

func (*PetGetURL) SetBasePath

func (o *PetGetURL) 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 (*PetGetURL) String

func (o *PetGetURL) String() string

String returns the string representation of the path with query string

func (*PetGetURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetGetURL) WithBasePath

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

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 PetList

type PetList struct {
	Context *middleware.Context
	Handler PetListHandler
}

PetList swagger:route GET /pet pet petList

List pets

func NewPetList

func NewPetList(ctx *middleware.Context, handler PetListHandler) *PetList

NewPetList creates a new http.Handler for the pet list operation

func (*PetList) ServeHTTP

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

type PetListBadRequest

type PetListBadRequest struct {
}

PetListBadRequest Invalid status value

swagger:response petListBadRequest

func NewPetListBadRequest

func NewPetListBadRequest() *PetListBadRequest

NewPetListBadRequest creates PetListBadRequest with default headers values

func (*PetListBadRequest) WriteResponse

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

WriteResponse to the client

type PetListHandler

type PetListHandler interface {
	Handle(PetListParams, interface{}) middleware.Responder
}

PetListHandler interface for that can handle valid pet list params

type PetListHandlerFunc

type PetListHandlerFunc func(PetListParams, interface{}) middleware.Responder

PetListHandlerFunc turns a function with the right signature into a pet list handler

func (PetListHandlerFunc) Handle

func (fn PetListHandlerFunc) Handle(params PetListParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetListOK

type PetListOK struct {

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

PetListOK successful operation

swagger:response petListOK

func NewPetListOK

func NewPetListOK() *PetListOK

NewPetListOK creates PetListOK with default headers values

func (*PetListOK) SetPayload

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

SetPayload sets the payload to the pet list o k response

func (*PetListOK) WithPayload

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

WithPayload adds the payload to the pet list o k response

func (*PetListOK) WriteResponse

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

WriteResponse to the client

type PetListParams

type PetListParams struct {

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

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

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

swagger:parameters PetList

func NewPetListParams

func NewPetListParams() PetListParams

NewPetListParams creates a new PetListParams object no default values defined in spec.

func (*PetListParams) BindRequest

func (o *PetListParams) 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 NewPetListParams() beforehand.

type PetListURL

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

PetListURL generates an URL for the pet list operation

func (*PetListURL) Build

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

Build a url path and query string

func (*PetListURL) BuildFull

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

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

func (*PetListURL) Must

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

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

func (*PetListURL) SetBasePath

func (o *PetListURL) 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 (*PetListURL) String

func (o *PetListURL) String() string

String returns the string representation of the path with query string

func (*PetListURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetListURL) WithBasePath

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

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 PetUpdate

type PetUpdate struct {
	Context *middleware.Context
	Handler PetUpdateHandler
}

PetUpdate swagger:route PUT /pet pet petUpdate

Update an existing pet

func NewPetUpdate

func NewPetUpdate(ctx *middleware.Context, handler PetUpdateHandler) *PetUpdate

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

func (*PetUpdate) ServeHTTP

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

type PetUpdateBadRequest

type PetUpdateBadRequest struct {
}

PetUpdateBadRequest Invalid ID supplied

swagger:response petUpdateBadRequest

func NewPetUpdateBadRequest

func NewPetUpdateBadRequest() *PetUpdateBadRequest

NewPetUpdateBadRequest creates PetUpdateBadRequest with default headers values

func (*PetUpdateBadRequest) WriteResponse

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

WriteResponse to the client

type PetUpdateCreated

type PetUpdateCreated struct {

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

PetUpdateCreated Updated successfully

swagger:response petUpdateCreated

func NewPetUpdateCreated

func NewPetUpdateCreated() *PetUpdateCreated

NewPetUpdateCreated creates PetUpdateCreated with default headers values

func (*PetUpdateCreated) SetPayload

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

SetPayload sets the payload to the pet update created response

func (*PetUpdateCreated) WithPayload

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

WithPayload adds the payload to the pet update created response

func (*PetUpdateCreated) WriteResponse

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

WriteResponse to the client

type PetUpdateHandler

type PetUpdateHandler interface {
	Handle(PetUpdateParams, interface{}) middleware.Responder
}

PetUpdateHandler interface for that can handle valid pet update params

type PetUpdateHandlerFunc

type PetUpdateHandlerFunc func(PetUpdateParams, interface{}) middleware.Responder

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

func (PetUpdateHandlerFunc) Handle

func (fn PetUpdateHandlerFunc) Handle(params PetUpdateParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetUpdateMethodNotAllowed

type PetUpdateMethodNotAllowed struct {
}

PetUpdateMethodNotAllowed Validation exception

swagger:response petUpdateMethodNotAllowed

func NewPetUpdateMethodNotAllowed

func NewPetUpdateMethodNotAllowed() *PetUpdateMethodNotAllowed

NewPetUpdateMethodNotAllowed creates PetUpdateMethodNotAllowed with default headers values

func (*PetUpdateMethodNotAllowed) WriteResponse

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

WriteResponse to the client

type PetUpdateNotFound

type PetUpdateNotFound struct {
}

PetUpdateNotFound Pet not found

swagger:response petUpdateNotFound

func NewPetUpdateNotFound

func NewPetUpdateNotFound() *PetUpdateNotFound

NewPetUpdateNotFound creates PetUpdateNotFound with default headers values

func (*PetUpdateNotFound) WriteResponse

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

WriteResponse to the client

type PetUpdateParams

type PetUpdateParams struct {

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

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

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

swagger:parameters PetUpdate

func NewPetUpdateParams

func NewPetUpdateParams() PetUpdateParams

NewPetUpdateParams creates a new PetUpdateParams object no default values defined in spec.

func (*PetUpdateParams) BindRequest

func (o *PetUpdateParams) 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 NewPetUpdateParams() beforehand.

type PetUpdateURL

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

PetUpdateURL generates an URL for the pet update operation

func (*PetUpdateURL) Build

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

Build a url path and query string

func (*PetUpdateURL) BuildFull

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

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

func (*PetUpdateURL) Must

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

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

func (*PetUpdateURL) SetBasePath

func (o *PetUpdateURL) 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 (*PetUpdateURL) String

func (o *PetUpdateURL) String() string

String returns the string representation of the path with query string

func (*PetUpdateURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetUpdateURL) WithBasePath

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

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 PetUploadImage

type PetUploadImage struct {
	Context *middleware.Context
	Handler PetUploadImageHandler
}

PetUploadImage swagger:route POST /pet/{petId}/image pet petUploadImage

uploads an image

func NewPetUploadImage

func NewPetUploadImage(ctx *middleware.Context, handler PetUploadImageHandler) *PetUploadImage

NewPetUploadImage creates a new http.Handler for the pet upload image operation

func (*PetUploadImage) ServeHTTP

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

type PetUploadImageHandler

type PetUploadImageHandler interface {
	Handle(PetUploadImageParams, interface{}) middleware.Responder
}

PetUploadImageHandler interface for that can handle valid pet upload image params

type PetUploadImageHandlerFunc

type PetUploadImageHandlerFunc func(PetUploadImageParams, interface{}) middleware.Responder

PetUploadImageHandlerFunc turns a function with the right signature into a pet upload image handler

func (PetUploadImageHandlerFunc) Handle

func (fn PetUploadImageHandlerFunc) Handle(params PetUploadImageParams, principal interface{}) middleware.Responder

Handle executing the request and returning a response

type PetUploadImageOK

type PetUploadImageOK struct {

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

PetUploadImageOK successful operation

swagger:response petUploadImageOK

func NewPetUploadImageOK

func NewPetUploadImageOK() *PetUploadImageOK

NewPetUploadImageOK creates PetUploadImageOK with default headers values

func (*PetUploadImageOK) SetPayload

func (o *PetUploadImageOK) SetPayload(payload *models.APIResponse)

SetPayload sets the payload to the pet upload image o k response

func (*PetUploadImageOK) WithPayload

func (o *PetUploadImageOK) WithPayload(payload *models.APIResponse) *PetUploadImageOK

WithPayload adds the payload to the pet upload image o k response

func (*PetUploadImageOK) WriteResponse

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

WriteResponse to the client

type PetUploadImageParams

type PetUploadImageParams struct {

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

	/*Additional data to pass to server
	  In: formData
	*/
	AdditionalMetadata *string
	/*file to upload
	  In: formData
	*/
	File io.ReadCloser
	/*ID of pet to update
	  Required: true
	  In: path
	*/
	PetID int64
}

PetUploadImageParams contains all the bound params for the pet upload image operation typically these are obtained from a http.Request

swagger:parameters PetUploadImage

func NewPetUploadImageParams

func NewPetUploadImageParams() PetUploadImageParams

NewPetUploadImageParams creates a new PetUploadImageParams object no default values defined in spec.

func (*PetUploadImageParams) BindRequest

func (o *PetUploadImageParams) 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 NewPetUploadImageParams() beforehand.

type PetUploadImageURL

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

PetUploadImageURL generates an URL for the pet upload image operation

func (*PetUploadImageURL) Build

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

Build a url path and query string

func (*PetUploadImageURL) BuildFull

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

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

func (*PetUploadImageURL) Must

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

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

func (*PetUploadImageURL) SetBasePath

func (o *PetUploadImageURL) 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 (*PetUploadImageURL) String

func (o *PetUploadImageURL) String() string

String returns the string representation of the path with query string

func (*PetUploadImageURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PetUploadImageURL) WithBasePath

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

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