// Code generated by go-swagger; DO NOT EDIT.

package plan_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"
)

// ListCompletePlansOKCode is the HTTP code returned for type ListCompletePlansOK
const ListCompletePlansOKCode int = 200

/*ListCompletePlansOK Set of known plans returned in full

swagger:response listCompletePlansOK
*/
type ListCompletePlansOK struct {

	/*
	  In: Body
	*/
	Payload []*models.Plan `json:"body,omitempty"`
}

// NewListCompletePlansOK creates ListCompletePlansOK with default headers values
func NewListCompletePlansOK() *ListCompletePlansOK {

	return &ListCompletePlansOK{}
}

// WithPayload adds the payload to the list complete plans o k response
func (o *ListCompletePlansOK) WithPayload(payload []*models.Plan) *ListCompletePlansOK {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the list complete plans o k response
func (o *ListCompletePlansOK) SetPayload(payload []*models.Plan) {
	o.Payload = payload
}

// WriteResponse to the client
func (o *ListCompletePlansOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {

	rw.WriteHeader(200)
	payload := o.Payload
	if payload == nil {
		// return empty array
		payload = make([]*models.Plan, 0, 50)
	}

	if err := producer.Produce(rw, payload); err != nil {
		panic(err) // let the recovery middleware deal with this
	}
}

// ListCompletePlansInternalServerErrorCode is the HTTP code returned for type ListCompletePlansInternalServerError
const ListCompletePlansInternalServerErrorCode int = 500

/*ListCompletePlansInternalServerError unexpected error

swagger:response listCompletePlansInternalServerError
*/
type ListCompletePlansInternalServerError struct {

	/*
	  In: Body
	*/
	Payload *models.ErrorResponse `json:"body,omitempty"`
}

// NewListCompletePlansInternalServerError creates ListCompletePlansInternalServerError with default headers values
func NewListCompletePlansInternalServerError() *ListCompletePlansInternalServerError {

	return &ListCompletePlansInternalServerError{}
}

// WithPayload adds the payload to the list complete plans internal server error response
func (o *ListCompletePlansInternalServerError) WithPayload(payload *models.ErrorResponse) *ListCompletePlansInternalServerError {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the list complete plans internal server error response
func (o *ListCompletePlansInternalServerError) SetPayload(payload *models.ErrorResponse) {
	o.Payload = payload
}

// WriteResponse to the client
func (o *ListCompletePlansInternalServerError) 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
		}
	}
}
