// Code generated by go-swagger; DO NOT EDIT. package agent // 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" ) // RemoteStatusOKCode is the HTTP code returned for type RemoteStatusOK const RemoteStatusOKCode int = 200 /* RemoteStatusOK ok swagger:response remoteStatusOK */ type RemoteStatusOK struct { /* In: Body */ Payload *RemoteStatusOKBody `json:"body,omitempty"` } // NewRemoteStatusOK creates RemoteStatusOK with default headers values func NewRemoteStatusOK() *RemoteStatusOK { return &RemoteStatusOK{} } // WithPayload adds the payload to the remote status o k response func (o *RemoteStatusOK) WithPayload(payload *RemoteStatusOKBody) *RemoteStatusOK { o.Payload = payload return o } // SetPayload sets the payload to the remote status o k response func (o *RemoteStatusOK) SetPayload(payload *RemoteStatusOKBody) { o.Payload = payload } // WriteResponse to the client func (o *RemoteStatusOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.WriteHeader(200) if o.Payload != nil { payload := o.Payload if err := producer.Produce(rw, payload); err != nil { panic(err) // let the recovery middleware deal with this } } } // RemoteStatusUnauthorizedCode is the HTTP code returned for type RemoteStatusUnauthorized const RemoteStatusUnauthorizedCode int = 401 /* RemoteStatusUnauthorized unauthorized swagger:response remoteStatusUnauthorized */ type RemoteStatusUnauthorized struct { } // NewRemoteStatusUnauthorized creates RemoteStatusUnauthorized with default headers values func NewRemoteStatusUnauthorized() *RemoteStatusUnauthorized { return &RemoteStatusUnauthorized{} } // WriteResponse to the client func (o *RemoteStatusUnauthorized) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses rw.WriteHeader(401) } // RemoteStatusInternalServerErrorCode is the HTTP code returned for type RemoteStatusInternalServerError const RemoteStatusInternalServerErrorCode int = 500 /* RemoteStatusInternalServerError internal server error swagger:response remoteStatusInternalServerError */ type RemoteStatusInternalServerError struct { } // NewRemoteStatusInternalServerError creates RemoteStatusInternalServerError with default headers values func NewRemoteStatusInternalServerError() *RemoteStatusInternalServerError { return &RemoteStatusInternalServerError{} } // WriteResponse to the client func (o *RemoteStatusInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses rw.WriteHeader(500) } // RemoteStatusBadGatewayCode is the HTTP code returned for type RemoteStatusBadGateway const RemoteStatusBadGatewayCode int = 502 /* RemoteStatusBadGateway bad gateway; agent not reachable swagger:response remoteStatusBadGateway */ type RemoteStatusBadGateway struct { } // NewRemoteStatusBadGateway creates RemoteStatusBadGateway with default headers values func NewRemoteStatusBadGateway() *RemoteStatusBadGateway { return &RemoteStatusBadGateway{} } // WriteResponse to the client func (o *RemoteStatusBadGateway) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) { rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses rw.WriteHeader(502) }