// Code generated by go-swagger; DO NOT EDIT. package identity // 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/openziti-test-kitchen/zrok/rest_model_zrok" ) // CreateAccountCreatedCode is the HTTP code returned for type CreateAccountCreated const CreateAccountCreatedCode int = 201 /*CreateAccountCreated account created swagger:response createAccountCreated */ type CreateAccountCreated struct { /* In: Body */ Payload *rest_model_zrok.AccountResponse `json:"body,omitempty"` } // NewCreateAccountCreated creates CreateAccountCreated with default headers values func NewCreateAccountCreated() *CreateAccountCreated { return &CreateAccountCreated{} } // WithPayload adds the payload to the create account created response func (o *CreateAccountCreated) WithPayload(payload *rest_model_zrok.AccountResponse) *CreateAccountCreated { o.Payload = payload return o } // SetPayload sets the payload to the create account created response func (o *CreateAccountCreated) SetPayload(payload *rest_model_zrok.AccountResponse) { o.Payload = payload } // WriteResponse to the client func (o *CreateAccountCreated) 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 } } } // CreateAccountBadRequestCode is the HTTP code returned for type CreateAccountBadRequest const CreateAccountBadRequestCode int = 400 /*CreateAccountBadRequest account not created (already exists) swagger:response createAccountBadRequest */ type CreateAccountBadRequest struct { /* In: Body */ Payload rest_model_zrok.ErrorMessage `json:"body,omitempty"` } // NewCreateAccountBadRequest creates CreateAccountBadRequest with default headers values func NewCreateAccountBadRequest() *CreateAccountBadRequest { return &CreateAccountBadRequest{} } // WithPayload adds the payload to the create account bad request response func (o *CreateAccountBadRequest) WithPayload(payload rest_model_zrok.ErrorMessage) *CreateAccountBadRequest { o.Payload = payload return o } // SetPayload sets the payload to the create account bad request response func (o *CreateAccountBadRequest) SetPayload(payload rest_model_zrok.ErrorMessage) { o.Payload = payload } // WriteResponse to the client func (o *CreateAccountBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.WriteHeader(400) payload := o.Payload if err := producer.Produce(rw, payload); err != nil { panic(err) // let the recovery middleware deal with this } } // CreateAccountInternalServerErrorCode is the HTTP code returned for type CreateAccountInternalServerError const CreateAccountInternalServerErrorCode int = 500 /*CreateAccountInternalServerError internal server error swagger:response createAccountInternalServerError */ type CreateAccountInternalServerError struct { /* In: Body */ Payload rest_model_zrok.ErrorMessage `json:"body,omitempty"` } // NewCreateAccountInternalServerError creates CreateAccountInternalServerError with default headers values func NewCreateAccountInternalServerError() *CreateAccountInternalServerError { return &CreateAccountInternalServerError{} } // WithPayload adds the payload to the create account internal server error response func (o *CreateAccountInternalServerError) WithPayload(payload rest_model_zrok.ErrorMessage) *CreateAccountInternalServerError { o.Payload = payload return o } // SetPayload sets the payload to the create account internal server error response func (o *CreateAccountInternalServerError) SetPayload(payload rest_model_zrok.ErrorMessage) { o.Payload = payload } // WriteResponse to the client func (o *CreateAccountInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.WriteHeader(500) payload := o.Payload if err := producer.Produce(rw, payload); err != nil { panic(err) // let the recovery middleware deal with this } }