func (o *CreateResolverAccepted) 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)  
		}
	}
}
WriteResponse to the client
package resolver
import (
	"net/http"
	"github.com/go-openapi/runtime"
	"github.com/haproxytech/client-native/v2/models"
)
const CreateResolverCreatedCode int = 201
type CreateResolverCreated struct {
	Payload *models.Resolver `json:"body,omitempty"`
}
func NewCreateResolverCreated() *CreateResolverCreated {
	return &CreateResolverCreated{}
}
func (o *CreateResolverCreated) WithPayload(payload *models.Resolver) *CreateResolverCreated {
	o.Payload = payload
	return o
}
func (o *CreateResolverCreated) SetPayload(payload *models.Resolver) {
	o.Payload = payload
}
func (o *CreateResolverCreated) 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 CreateResolverAcceptedCode int = 202
type CreateResolverAccepted struct {
	ReloadID string `json:"Reload-ID"`
	Payload *models.Resolver `json:"body,omitempty"`
}
func NewCreateResolverAccepted() *CreateResolverAccepted {
	return &CreateResolverAccepted{}
}
func (o *CreateResolverAccepted) WithReloadID(reloadID string) *CreateResolverAccepted {
	o.ReloadID = reloadID
	return o
}
func (o *CreateResolverAccepted) SetReloadID(reloadID string) {
	o.ReloadID = reloadID
}
func (o *CreateResolverAccepted) WithPayload(payload *models.Resolver) *CreateResolverAccepted {
	o.Payload = payload
	return o
}
func (o *CreateResolverAccepted) SetPayload(payload *models.Resolver) {
	o.Payload = payload
}