You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
170 lines
4.6 KiB
170 lines
4.6 KiB
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
package cycle_management
|
|
|
|
// 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/Cyclops-Labs/cyclops-4-hpc.git/services/plan-manager/models"
|
|
)
|
|
|
|
// CreateCycleCreatedCode is the HTTP code returned for type CreateCycleCreated
|
|
const CreateCycleCreatedCode int = 201
|
|
|
|
/*CreateCycleCreated item created
|
|
|
|
swagger:response createCycleCreated
|
|
*/
|
|
type CreateCycleCreated struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *models.ItemCreatedResponse `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewCreateCycleCreated creates CreateCycleCreated with default headers values
|
|
func NewCreateCycleCreated() *CreateCycleCreated {
|
|
|
|
return &CreateCycleCreated{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the create cycle created response
|
|
func (o *CreateCycleCreated) WithPayload(payload *models.ItemCreatedResponse) *CreateCycleCreated {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the create cycle created response
|
|
func (o *CreateCycleCreated) SetPayload(payload *models.ItemCreatedResponse) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *CreateCycleCreated) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(201)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// CreateCycleBadRequestCode is the HTTP code returned for type CreateCycleBadRequest
|
|
const CreateCycleBadRequestCode int = 400
|
|
|
|
/*CreateCycleBadRequest invalid input, object invalid
|
|
|
|
swagger:response createCycleBadRequest
|
|
*/
|
|
type CreateCycleBadRequest struct {
|
|
}
|
|
|
|
// NewCreateCycleBadRequest creates CreateCycleBadRequest with default headers values
|
|
func NewCreateCycleBadRequest() *CreateCycleBadRequest {
|
|
|
|
return &CreateCycleBadRequest{}
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *CreateCycleBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses
|
|
|
|
rw.WriteHeader(400)
|
|
}
|
|
|
|
// CreateCycleConflictCode is the HTTP code returned for type CreateCycleConflict
|
|
const CreateCycleConflictCode int = 409
|
|
|
|
/*CreateCycleConflict an existing item already exists
|
|
|
|
swagger:response createCycleConflict
|
|
*/
|
|
type CreateCycleConflict struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *models.ErrorResponse `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewCreateCycleConflict creates CreateCycleConflict with default headers values
|
|
func NewCreateCycleConflict() *CreateCycleConflict {
|
|
|
|
return &CreateCycleConflict{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the create cycle conflict response
|
|
func (o *CreateCycleConflict) WithPayload(payload *models.ErrorResponse) *CreateCycleConflict {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the create cycle conflict response
|
|
func (o *CreateCycleConflict) SetPayload(payload *models.ErrorResponse) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *CreateCycleConflict) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(409)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// CreateCycleInternalServerErrorCode is the HTTP code returned for type CreateCycleInternalServerError
|
|
const CreateCycleInternalServerErrorCode int = 500
|
|
|
|
/*CreateCycleInternalServerError unexpected error
|
|
|
|
swagger:response createCycleInternalServerError
|
|
*/
|
|
type CreateCycleInternalServerError struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *models.ErrorResponse `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewCreateCycleInternalServerError creates CreateCycleInternalServerError with default headers values
|
|
func NewCreateCycleInternalServerError() *CreateCycleInternalServerError {
|
|
|
|
return &CreateCycleInternalServerError{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the create cycle internal server error response
|
|
func (o *CreateCycleInternalServerError) WithPayload(payload *models.ErrorResponse) *CreateCycleInternalServerError {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the create cycle internal server error response
|
|
func (o *CreateCycleInternalServerError) SetPayload(payload *models.ErrorResponse) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *CreateCycleInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(500)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|