2022-08-03 20:36:40 +02:00
|
|
|
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
|
|
|
|
package metadata
|
|
|
|
|
|
|
|
// 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"
|
|
|
|
|
2023-01-13 21:01:34 +01:00
|
|
|
"github.com/openziti/zrok/rest_model_zrok"
|
2022-08-03 20:36:40 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
// OverviewOKCode is the HTTP code returned for type OverviewOK
|
|
|
|
const OverviewOKCode int = 200
|
|
|
|
|
2022-09-01 23:39:02 +02:00
|
|
|
/*
|
|
|
|
OverviewOK overview returned
|
2022-08-03 20:36:40 +02:00
|
|
|
|
|
|
|
swagger:response overviewOK
|
|
|
|
*/
|
|
|
|
type OverviewOK struct {
|
|
|
|
|
|
|
|
/*
|
|
|
|
In: Body
|
|
|
|
*/
|
2023-01-04 19:43:37 +01:00
|
|
|
Payload rest_model_zrok.EnvironmentSharesList `json:"body,omitempty"`
|
2022-08-03 20:36:40 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// NewOverviewOK creates OverviewOK with default headers values
|
|
|
|
func NewOverviewOK() *OverviewOK {
|
|
|
|
|
|
|
|
return &OverviewOK{}
|
|
|
|
}
|
|
|
|
|
|
|
|
// WithPayload adds the payload to the overview o k response
|
2023-01-04 19:43:37 +01:00
|
|
|
func (o *OverviewOK) WithPayload(payload rest_model_zrok.EnvironmentSharesList) *OverviewOK {
|
2022-08-03 20:36:40 +02:00
|
|
|
o.Payload = payload
|
|
|
|
return o
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetPayload sets the payload to the overview o k response
|
2023-01-04 19:43:37 +01:00
|
|
|
func (o *OverviewOK) SetPayload(payload rest_model_zrok.EnvironmentSharesList) {
|
2022-08-03 20:36:40 +02:00
|
|
|
o.Payload = payload
|
|
|
|
}
|
|
|
|
|
|
|
|
// WriteResponse to the client
|
|
|
|
func (o *OverviewOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
|
|
|
|
rw.WriteHeader(200)
|
2022-08-03 21:05:28 +02:00
|
|
|
payload := o.Payload
|
|
|
|
if payload == nil {
|
|
|
|
// return empty array
|
2023-01-04 19:43:37 +01:00
|
|
|
payload = rest_model_zrok.EnvironmentSharesList{}
|
2022-08-03 21:05:28 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
|
|
panic(err) // let the recovery middleware deal with this
|
2022-08-03 20:36:40 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// OverviewInternalServerErrorCode is the HTTP code returned for type OverviewInternalServerError
|
|
|
|
const OverviewInternalServerErrorCode int = 500
|
|
|
|
|
2022-09-01 23:39:02 +02:00
|
|
|
/*
|
|
|
|
OverviewInternalServerError internal server error
|
2022-08-03 20:36:40 +02:00
|
|
|
|
|
|
|
swagger:response overviewInternalServerError
|
|
|
|
*/
|
|
|
|
type OverviewInternalServerError struct {
|
|
|
|
|
|
|
|
/*
|
|
|
|
In: Body
|
|
|
|
*/
|
|
|
|
Payload rest_model_zrok.ErrorMessage `json:"body,omitempty"`
|
|
|
|
}
|
|
|
|
|
|
|
|
// NewOverviewInternalServerError creates OverviewInternalServerError with default headers values
|
|
|
|
func NewOverviewInternalServerError() *OverviewInternalServerError {
|
|
|
|
|
|
|
|
return &OverviewInternalServerError{}
|
|
|
|
}
|
|
|
|
|
|
|
|
// WithPayload adds the payload to the overview internal server error response
|
|
|
|
func (o *OverviewInternalServerError) WithPayload(payload rest_model_zrok.ErrorMessage) *OverviewInternalServerError {
|
|
|
|
o.Payload = payload
|
|
|
|
return o
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetPayload sets the payload to the overview internal server error response
|
|
|
|
func (o *OverviewInternalServerError) SetPayload(payload rest_model_zrok.ErrorMessage) {
|
|
|
|
o.Payload = payload
|
|
|
|
}
|
|
|
|
|
|
|
|
// WriteResponse to the client
|
|
|
|
func (o *OverviewInternalServerError) 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
|
|
|
|
}
|
|
|
|
}
|