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

package product_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/customerdb/models"
)

// AddProductCreatedCode is the HTTP code returned for type AddProductCreated
const AddProductCreatedCode int = 201

/*AddProductCreated New product was added successfully

swagger:response addProductCreated
*/
type AddProductCreated struct {

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

// NewAddProductCreated creates AddProductCreated with default headers values
func NewAddProductCreated() *AddProductCreated {

	return &AddProductCreated{}
}

// WithPayload adds the payload to the add product created response
func (o *AddProductCreated) WithPayload(payload *models.ItemCreatedResponse) *AddProductCreated {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the add product created response
func (o *AddProductCreated) SetPayload(payload *models.ItemCreatedResponse) {
	o.Payload = payload
}

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

// AddProductBadRequestCode is the HTTP code returned for type AddProductBadRequest
const AddProductBadRequestCode int = 400

/*AddProductBadRequest Invalid input, object invalid

swagger:response addProductBadRequest
*/
type AddProductBadRequest struct {
}

// NewAddProductBadRequest creates AddProductBadRequest with default headers values
func NewAddProductBadRequest() *AddProductBadRequest {

	return &AddProductBadRequest{}
}

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

	rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses

	rw.WriteHeader(400)
}

// AddProductConflictCode is the HTTP code returned for type AddProductConflict
const AddProductConflictCode int = 409

/*AddProductConflict The given item already exists

swagger:response addProductConflict
*/
type AddProductConflict struct {

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

// NewAddProductConflict creates AddProductConflict with default headers values
func NewAddProductConflict() *AddProductConflict {

	return &AddProductConflict{}
}

// WithPayload adds the payload to the add product conflict response
func (o *AddProductConflict) WithPayload(payload *models.ErrorResponse) *AddProductConflict {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the add product conflict response
func (o *AddProductConflict) SetPayload(payload *models.ErrorResponse) {
	o.Payload = payload
}

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

// AddProductInternalServerErrorCode is the HTTP code returned for type AddProductInternalServerError
const AddProductInternalServerErrorCode int = 500

/*AddProductInternalServerError Something unexpected happend, error raised

swagger:response addProductInternalServerError
*/
type AddProductInternalServerError struct {

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

// NewAddProductInternalServerError creates AddProductInternalServerError with default headers values
func NewAddProductInternalServerError() *AddProductInternalServerError {

	return &AddProductInternalServerError{}
}

// WithPayload adds the payload to the add product internal server error response
func (o *AddProductInternalServerError) WithPayload(payload *models.ErrorResponse) *AddProductInternalServerError {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the add product internal server error response
func (o *AddProductInternalServerError) SetPayload(payload *models.ErrorResponse) {
	o.Payload = payload
}

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