mirror of
https://github.com/openziti/ziti.git
synced 2026-10-12 07:18:36 +00:00
259 lines
7.4 KiB
Go
259 lines
7.4 KiB
Go
// Code generated by go-swagger; DO NOT EDIT.
|
|
|
|
//
|
|
// Copyright NetFoundry Inc.
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// https://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
//
|
|
// __ __ _
|
|
// \ \ / / (_)
|
|
// \ \ /\ / /_ _ _ __ _ __ _ _ __ __ _
|
|
// \ \/ \/ / _` | '__| '_ \| | '_ \ / _` |
|
|
// \ /\ / (_| | | | | | | | | | | (_| | : This file is generated, do not edit it.
|
|
// \/ \/ \__,_|_| |_| |_|_|_| |_|\__, |
|
|
// __/ |
|
|
// |___/
|
|
|
|
package link
|
|
|
|
// 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/ziti/controller/rest_model"
|
|
)
|
|
|
|
// PatchLinkOKCode is the HTTP code returned for type PatchLinkOK
|
|
const PatchLinkOKCode int = 200
|
|
|
|
/*PatchLinkOK The patch request was successful and the resource has been altered
|
|
|
|
swagger:response patchLinkOK
|
|
*/
|
|
type PatchLinkOK struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *rest_model.Empty `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewPatchLinkOK creates PatchLinkOK with default headers values
|
|
func NewPatchLinkOK() *PatchLinkOK {
|
|
|
|
return &PatchLinkOK{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the patch link o k response
|
|
func (o *PatchLinkOK) WithPayload(payload *rest_model.Empty) *PatchLinkOK {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the patch link o k response
|
|
func (o *PatchLinkOK) SetPayload(payload *rest_model.Empty) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *PatchLinkOK) 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
|
|
}
|
|
}
|
|
}
|
|
|
|
// PatchLinkBadRequestCode is the HTTP code returned for type PatchLinkBadRequest
|
|
const PatchLinkBadRequestCode int = 400
|
|
|
|
/*PatchLinkBadRequest The supplied request contains invalid fields or could not be parsed (json and non-json bodies). The error's code, message, and cause fields can be inspected for further information
|
|
|
|
swagger:response patchLinkBadRequest
|
|
*/
|
|
type PatchLinkBadRequest struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *rest_model.APIErrorEnvelope `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewPatchLinkBadRequest creates PatchLinkBadRequest with default headers values
|
|
func NewPatchLinkBadRequest() *PatchLinkBadRequest {
|
|
|
|
return &PatchLinkBadRequest{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the patch link bad request response
|
|
func (o *PatchLinkBadRequest) WithPayload(payload *rest_model.APIErrorEnvelope) *PatchLinkBadRequest {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the patch link bad request response
|
|
func (o *PatchLinkBadRequest) SetPayload(payload *rest_model.APIErrorEnvelope) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *PatchLinkBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(400)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// PatchLinkUnauthorizedCode is the HTTP code returned for type PatchLinkUnauthorized
|
|
const PatchLinkUnauthorizedCode int = 401
|
|
|
|
/*PatchLinkUnauthorized The currently supplied session does not have the correct access rights to request this resource
|
|
|
|
swagger:response patchLinkUnauthorized
|
|
*/
|
|
type PatchLinkUnauthorized struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *rest_model.APIErrorEnvelope `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewPatchLinkUnauthorized creates PatchLinkUnauthorized with default headers values
|
|
func NewPatchLinkUnauthorized() *PatchLinkUnauthorized {
|
|
|
|
return &PatchLinkUnauthorized{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the patch link unauthorized response
|
|
func (o *PatchLinkUnauthorized) WithPayload(payload *rest_model.APIErrorEnvelope) *PatchLinkUnauthorized {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the patch link unauthorized response
|
|
func (o *PatchLinkUnauthorized) SetPayload(payload *rest_model.APIErrorEnvelope) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *PatchLinkUnauthorized) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(401)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// PatchLinkNotFoundCode is the HTTP code returned for type PatchLinkNotFound
|
|
const PatchLinkNotFoundCode int = 404
|
|
|
|
/*PatchLinkNotFound The requested resource does not exist
|
|
|
|
swagger:response patchLinkNotFound
|
|
*/
|
|
type PatchLinkNotFound struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *rest_model.APIErrorEnvelope `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewPatchLinkNotFound creates PatchLinkNotFound with default headers values
|
|
func NewPatchLinkNotFound() *PatchLinkNotFound {
|
|
|
|
return &PatchLinkNotFound{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the patch link not found response
|
|
func (o *PatchLinkNotFound) WithPayload(payload *rest_model.APIErrorEnvelope) *PatchLinkNotFound {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the patch link not found response
|
|
func (o *PatchLinkNotFound) SetPayload(payload *rest_model.APIErrorEnvelope) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *PatchLinkNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(404)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|
|
|
|
// PatchLinkTooManyRequestsCode is the HTTP code returned for type PatchLinkTooManyRequests
|
|
const PatchLinkTooManyRequestsCode int = 429
|
|
|
|
/*PatchLinkTooManyRequests The resource requested is rate limited and the rate limit has been exceeded
|
|
|
|
swagger:response patchLinkTooManyRequests
|
|
*/
|
|
type PatchLinkTooManyRequests struct {
|
|
|
|
/*
|
|
In: Body
|
|
*/
|
|
Payload *rest_model.APIErrorEnvelope `json:"body,omitempty"`
|
|
}
|
|
|
|
// NewPatchLinkTooManyRequests creates PatchLinkTooManyRequests with default headers values
|
|
func NewPatchLinkTooManyRequests() *PatchLinkTooManyRequests {
|
|
|
|
return &PatchLinkTooManyRequests{}
|
|
}
|
|
|
|
// WithPayload adds the payload to the patch link too many requests response
|
|
func (o *PatchLinkTooManyRequests) WithPayload(payload *rest_model.APIErrorEnvelope) *PatchLinkTooManyRequests {
|
|
o.Payload = payload
|
|
return o
|
|
}
|
|
|
|
// SetPayload sets the payload to the patch link too many requests response
|
|
func (o *PatchLinkTooManyRequests) SetPayload(payload *rest_model.APIErrorEnvelope) {
|
|
o.Payload = payload
|
|
}
|
|
|
|
// WriteResponse to the client
|
|
func (o *PatchLinkTooManyRequests) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {
|
|
|
|
rw.WriteHeader(429)
|
|
if o.Payload != nil {
|
|
payload := o.Payload
|
|
if err := producer.Produce(rw, payload); err != nil {
|
|
panic(err) // let the recovery middleware deal with this
|
|
}
|
|
}
|
|
}
|