create_task

package
v0.0.0-...-037b8db Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const PostTaskNoContentCode int = 204

PostTaskNoContentCode is the HTTP code returned for type PostTaskNoContent

Variables

This section is empty.

Functions

This section is empty.

Types

type PostTask

type PostTask struct {
	Context *middleware.Context
	Handler PostTaskHandler
}

PostTask swagger:route POST /task createTask postTask

Create new task

func NewPostTask

func NewPostTask(ctx *middleware.Context, handler PostTaskHandler) *PostTask

NewPostTask creates a new http.Handler for the post task operation

func (*PostTask) ServeHTTP

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

type PostTaskHandler

type PostTaskHandler interface {
	Handle(PostTaskParams) middleware.Responder
}

PostTaskHandler interface for that can handle valid post task params

type PostTaskHandlerFunc

type PostTaskHandlerFunc func(PostTaskParams) middleware.Responder

PostTaskHandlerFunc turns a function with the right signature into a post task handler

func (PostTaskHandlerFunc) Handle

Handle executing the request and returning a response

type PostTaskNoContent

type PostTaskNoContent struct {
}

PostTaskNoContent OK No Content

swagger:response postTaskNoContent

func NewPostTaskNoContent

func NewPostTaskNoContent() *PostTaskNoContent

NewPostTaskNoContent creates PostTaskNoContent with default headers values

func (*PostTaskNoContent) WriteResponse

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

WriteResponse to the client

type PostTaskParams

type PostTaskParams struct {

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

	/*
	  Required: true
	  In: body
	*/
	Body *models.RequestTask
}

PostTaskParams contains all the bound params for the post task operation typically these are obtained from a http.Request

swagger:parameters PostTask

func NewPostTaskParams

func NewPostTaskParams() PostTaskParams

NewPostTaskParams creates a new PostTaskParams object no default values defined in spec.

func (*PostTaskParams) BindRequest

func (o *PostTaskParams) 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 NewPostTaskParams() beforehand.

type PostTaskURL

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

PostTaskURL generates an URL for the post task operation

func (*PostTaskURL) Build

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

Build a url path and query string

func (*PostTaskURL) BuildFull

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

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

func (*PostTaskURL) Must

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

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

func (*PostTaskURL) SetBasePath

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

func (o *PostTaskURL) String() string

String returns the string representation of the path with query string

func (*PostTaskURL) StringFull

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

StringFull returns the string representation of a complete url

func (*PostTaskURL) WithBasePath

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

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