forked from TrueCloudLab/frostfs-rest-gw
9fba8d7f23
Signed-off-by: Denis Kirillov <denis@nspcc.ru>
102 lines
2.6 KiB
Go
102 lines
2.6 KiB
Go
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
package operations
|
|
|
|
// This file was generated by the swagger tool.
|
|
// Editing this file might prove futile when you re-run the swagger generate command
|
|
|
|
import (
|
|
"net/http"
|
|
|
|
"github.com/go-openapi/runtime"
|
|
|
|
"github.com/nspcc-dev/neofs-rest-gw/gen/models"
|
|
)
|
|
|
|
// SearchObjectsOKCode is the HTTP code returned for type SearchObjectsOK
|
|
const SearchObjectsOKCode int = 200
|
|
|
|
/*SearchObjectsOK List of objects
|
|
|
|
swagger:response searchObjectsOK
|
|
*/
|
|
type SearchObjectsOK struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *models.ObjectList `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewSearchObjectsOK creates SearchObjectsOK with default headers values
|
|
func NewSearchObjectsOK() *SearchObjectsOK {
|
|
|
|
return &SearchObjectsOK{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the search objects o k response
|
|
func (o *SearchObjectsOK) WithPayload(payload *models.ObjectList) *SearchObjectsOK {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the search objects o k response
|
|
func (o *SearchObjectsOK) SetPayload(payload *models.ObjectList) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *SearchObjectsOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(200)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// SearchObjectsBadRequestCode is the HTTP code returned for type SearchObjectsBadRequest
|
|
const SearchObjectsBadRequestCode int = 400
|
|
|
|
/*SearchObjectsBadRequest Bad request
|
|
|
|
swagger:response searchObjectsBadRequest
|
|
*/
|
|
type SearchObjectsBadRequest struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *models.ErrorResponse `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewSearchObjectsBadRequest creates SearchObjectsBadRequest with default headers values
|
|
func NewSearchObjectsBadRequest() *SearchObjectsBadRequest {
|
|
|
|
return &SearchObjectsBadRequest{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the search objects bad request response
|
|
func (o *SearchObjectsBadRequest) WithPayload(payload *models.ErrorResponse) *SearchObjectsBadRequest {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the search objects bad request response
|
|
func (o *SearchObjectsBadRequest) SetPayload(payload *models.ErrorResponse) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *SearchObjectsBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(400)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|