github.com/cilium/cilium@v1.16.2/api/v1/health/server/restapi/get_healthz_parameters.go (about) 1 // Code generated by go-swagger; DO NOT EDIT. 2 3 // Copyright Authors of Cilium 4 // SPDX-License-Identifier: Apache-2.0 5 6 package restapi 7 8 // This file was generated by the swagger tool. 9 // Editing this file might prove futile when you re-run the swagger generate command 10 11 import ( 12 "net/http" 13 14 "github.com/go-openapi/errors" 15 "github.com/go-openapi/runtime/middleware" 16 ) 17 18 // NewGetHealthzParams creates a new GetHealthzParams object 19 // 20 // There are no default values defined in the spec. 21 func NewGetHealthzParams() GetHealthzParams { 22 23 return GetHealthzParams{} 24 } 25 26 // GetHealthzParams contains all the bound params for the get healthz operation 27 // typically these are obtained from a http.Request 28 // 29 // swagger:parameters GetHealthz 30 type GetHealthzParams struct { 31 32 // HTTP Request Object 33 HTTPRequest *http.Request `json:"-"` 34 } 35 36 // BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface 37 // for simple values it will use straight method calls. 38 // 39 // To ensure default values, the struct must have been initialized with NewGetHealthzParams() beforehand. 40 func (o *GetHealthzParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error { 41 var res []error 42 43 o.HTTPRequest = r 44 45 if len(res) > 0 { 46 return errors.CompositeValidationError(res...) 47 } 48 return nil 49 }