func (o *CreateTCPResponseRuleDefault) WithConfigurationVersion(configurationVersion string) *CreateTCPResponseRuleDefault {
	o.ConfigurationVersion = configurationVersion
	return o
}
WithConfigurationVersion adds the configurationVersion to the create TCP response rule default response
package tcp_response_rule
import (
	"net/http"
	"github.com/go-openapi/runtime"
	"github.com/haproxytech/client-native/v2/models"
)
const CreateTCPResponseRuleCreatedCode int = 201
type CreateTCPResponseRuleCreated struct {
	Payload *models.TCPResponseRule `json:"body,omitempty"`
}
func NewCreateTCPResponseRuleCreated() *CreateTCPResponseRuleCreated {
	return &CreateTCPResponseRuleCreated{}
}
func (o *CreateTCPResponseRuleCreated) WithPayload(payload *models.TCPResponseRule) *CreateTCPResponseRuleCreated {
	o.Payload = payload
	return o
}
func (o *CreateTCPResponseRuleCreated) SetPayload(payload *models.TCPResponseRule) {
	o.Payload = payload
}
func (o *CreateTCPResponseRuleCreated) 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)  
		}
	}
}
const CreateTCPResponseRuleAcceptedCode int = 202
type CreateTCPResponseRuleAccepted struct {
	ReloadID string `json:"Reload-ID"`
	Payload *models.TCPResponseRule `json:"body,omitempty"`
}
func NewCreateTCPResponseRuleAccepted() *CreateTCPResponseRuleAccepted {
	return &CreateTCPResponseRuleAccepted{}
}
func (o *CreateTCPResponseRuleAccepted) WithReloadID(reloadID string) *CreateTCPResponseRuleAccepted {
	o.ReloadID = reloadID
	return o
}
func (o *CreateTCPResponseRuleAccepted) SetReloadID(reloadID string) {
	o.ReloadID = reloadID
}
func (o *CreateTCPResponseRuleAccepted) WithPayload(payload *models.TCPResponseRule) *CreateTCPResponseRuleAccepted {
	o.Payload = payload
	return o
}
func (o *CreateTCPResponseRuleAccepted) SetPayload(payload *models.TCPResponseRule) {
	o.Payload = payload
}
func (o *CreateTCPResponseRuleAccepted) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
	reloadID := o.ReloadID
	if reloadID != "" {
		rw.Header().Set("Reload-ID", reloadID)
	}
	rw.WriteHeader(202)
	if o.Payload != nil {
		payload := o.Payload
		if err := producer.Produce(rw, payload); err != nil {
			panic(err)  
		}
	}
}
const CreateTCPResponseRuleBadRequestCode int = 400
type CreateTCPResponseRuleBadRequest struct {
	ConfigurationVersion string `json:"Configuration-Version"`
	Payload *models.Error `json:"body,omitempty"`
}
func NewCreateTCPResponseRuleBadRequest() *CreateTCPResponseRuleBadRequest {
	return &CreateTCPResponseRuleBadRequest{}
}
func (o *CreateTCPResponseRuleBadRequest) WithConfigurationVersion(configurationVersion string) *CreateTCPResponseRuleBadRequest {
	o.ConfigurationVersion = configurationVersion
	return o
}
func (o *CreateTCPResponseRuleBadRequest) SetConfigurationVersion(configurationVersion string) {
	o.ConfigurationVersion = configurationVersion
}
func (o *CreateTCPResponseRuleBadRequest) WithPayload(payload *models.Error) *CreateTCPResponseRuleBadRequest {
	o.Payload = payload
	return o
}
func (o *CreateTCPResponseRuleBadRequest) SetPayload(payload *models.Error) {
	o.Payload = payload
}
func (o *CreateTCPResponseRuleBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
	configurationVersion := o.ConfigurationVersion
	if configurationVersion != "" {
		rw.Header().Set("Configuration-Version", configurationVersion)
	}
	rw.WriteHeader(400)
	if o.Payload != nil {
		payload := o.Payload
		if err := producer.Produce(rw, payload); err != nil {
			panic(err)  
		}
	}
}
const CreateTCPResponseRuleConflictCode int = 409
type CreateTCPResponseRuleConflict struct {
	ConfigurationVersion string `json:"Configuration-Version"`
	Payload *models.Error `json:"body,omitempty"`
}
func NewCreateTCPResponseRuleConflict() *CreateTCPResponseRuleConflict {
	return &CreateTCPResponseRuleConflict{}
}
func (o *CreateTCPResponseRuleConflict) WithConfigurationVersion(configurationVersion string) *CreateTCPResponseRuleConflict {
	o.ConfigurationVersion = configurationVersion
	return o
}
func (o *CreateTCPResponseRuleConflict) SetConfigurationVersion(configurationVersion string) {
	o.ConfigurationVersion = configurationVersion
}
func (o *CreateTCPResponseRuleConflict) WithPayload(payload *models.Error) *CreateTCPResponseRuleConflict {
	o.Payload = payload
	return o
}
func (o *CreateTCPResponseRuleConflict) SetPayload(payload *models.Error) {
	o.Payload = payload
}
func (o *CreateTCPResponseRuleConflict) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
	configurationVersion := o.ConfigurationVersion
	if configurationVersion != "" {
		rw.Header().Set("Configuration-Version", configurationVersion)
	}
	rw.WriteHeader(409)
	if o.Payload != nil {
		payload := o.Payload
		if err := producer.Produce(rw, payload); err != nil {
			panic(err)  
		}
	}
}
type CreateTCPResponseRuleDefault struct {
	_statusCode int
	ConfigurationVersion string `json:"Configuration-Version"`
	Payload *models.Error `json:"body,omitempty"`
}
func NewCreateTCPResponseRuleDefault(code int) *CreateTCPResponseRuleDefault {
	if code <= 0 {
		code = 500
	}
	return &CreateTCPResponseRuleDefault{
		_statusCode: code,
	}
}
func (o *CreateTCPResponseRuleDefault) WithStatusCode(code int) *CreateTCPResponseRuleDefault {
	o._statusCode = code
	return o
}
func (o *CreateTCPResponseRuleDefault) SetStatusCode(code int) {
	o._statusCode = code
}