Documentation ¶
Index ¶
- Constants
- type Root
- type RootDefault
- func (o *RootDefault) SetPayload(payload *models.Error)
- func (o *RootDefault) SetStatusCode(code int)
- func (o *RootDefault) WithPayload(payload *models.Error) *RootDefault
- func (o *RootDefault) WithStatusCode(code int) *RootDefault
- func (o *RootDefault) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
- type RootHandler
- type RootHandlerFunc
- type RootOK
- type RootParams
- type RootURL
- func (o *RootURL) Build() (*url.URL, error)
- func (o *RootURL) BuildFull(scheme, host string) (*url.URL, error)
- func (o *RootURL) Must(u *url.URL, err error) *url.URL
- func (o *RootURL) SetBasePath(bp string)
- func (o *RootURL) String() string
- func (o *RootURL) StringFull(scheme, host string) string
- func (o *RootURL) WithBasePath(bp string) *RootURL
Constants ¶
const RootOKCode int = 200
RootOKCode is the HTTP code returned for type RootOK
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Root ¶
type Root struct { Context *middleware.Context Handler RootHandler }
Root swagger:route GET / swagger-server root
Root root API
func NewRoot ¶
func NewRoot(ctx *middleware.Context, handler RootHandler) *Root
NewRoot creates a new http.Handler for the root operation
type RootDefault ¶
type RootDefault struct { /* In: Body */ Payload *models.Error `json:"body,omitempty"` // contains filtered or unexported fields }
RootDefault generic error response
swagger:response rootDefault
func NewRootDefault ¶
func NewRootDefault(code int) *RootDefault
NewRootDefault creates RootDefault with default headers values
func (*RootDefault) SetPayload ¶
func (o *RootDefault) SetPayload(payload *models.Error)
SetPayload sets the payload to the root default response
func (*RootDefault) SetStatusCode ¶
func (o *RootDefault) SetStatusCode(code int)
SetStatusCode sets the status to the root default response
func (*RootDefault) WithPayload ¶
func (o *RootDefault) WithPayload(payload *models.Error) *RootDefault
WithPayload adds the payload to the root default response
func (*RootDefault) WithStatusCode ¶
func (o *RootDefault) WithStatusCode(code int) *RootDefault
WithStatusCode adds the status to the root default response
func (*RootDefault) WriteResponse ¶
func (o *RootDefault) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type RootHandler ¶
type RootHandler interface {
Handle(RootParams) middleware.Responder
}
RootHandler interface for that can handle valid root params
type RootHandlerFunc ¶
type RootHandlerFunc func(RootParams) middleware.Responder
RootHandlerFunc turns a function with the right signature into a root handler
func (RootHandlerFunc) Handle ¶
func (fn RootHandlerFunc) Handle(params RootParams) middleware.Responder
Handle executing the request and returning a response
type RootOK ¶
type RootOK struct { /* In: Body */ Payload string `json:"body,omitempty"` }
RootOK serves to display the root of the swagger API for the test bench
swagger:response rootOK
func (*RootOK) SetPayload ¶
SetPayload sets the payload to the root o k response
func (*RootOK) WithPayload ¶
WithPayload adds the payload to the root o k response
func (*RootOK) WriteResponse ¶
func (o *RootOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)
WriteResponse to the client
type RootParams ¶
RootParams contains all the bound params for the root operation typically these are obtained from a http.Request
swagger:parameters root
func NewRootParams ¶
func NewRootParams() RootParams
NewRootParams creates a new RootParams object
There are no default values defined in the spec.
func (*RootParams) BindRequest ¶
func (o *RootParams) 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 NewRootParams() beforehand.
type RootURL ¶
type RootURL struct {
// contains filtered or unexported fields
}
RootURL generates an URL for the root operation
func (*RootURL) SetBasePath ¶
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 (*RootURL) StringFull ¶
StringFull returns the string representation of a complete url
func (*RootURL) WithBasePath ¶
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