// Code generated by go-swagger; DO NOT EDIT.

// Copyright Authors of Cilium
// SPDX-License-Identifier: Apache-2.0

package policy

// 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/cilium/cilium/api/v1/models"
)

// GetIdentityEndpointsOKCode is the HTTP code returned for type GetIdentityEndpointsOK
const GetIdentityEndpointsOKCode int = 200

/*
GetIdentityEndpointsOK Success

swagger:response getIdentityEndpointsOK
*/
type GetIdentityEndpointsOK struct {

	/*
	  In: Body
	*/
	Payload []*models.IdentityEndpoints `json:"body,omitempty"`
}

// NewGetIdentityEndpointsOK creates GetIdentityEndpointsOK with default headers values
func NewGetIdentityEndpointsOK() *GetIdentityEndpointsOK {

	return &GetIdentityEndpointsOK{}
}

// WithPayload adds the payload to the get identity endpoints o k response
func (o *GetIdentityEndpointsOK) WithPayload(payload []*models.IdentityEndpoints) *GetIdentityEndpointsOK {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the get identity endpoints o k response
func (o *GetIdentityEndpointsOK) SetPayload(payload []*models.IdentityEndpoints) {
	o.Payload = payload
}

// WriteResponse to the client
func (o *GetIdentityEndpointsOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {

	rw.WriteHeader(200)
	payload := o.Payload
	if payload == nil {
		// return empty array
		payload = make([]*models.IdentityEndpoints, 0, 50)
	}

	if err := producer.Produce(rw, payload); err != nil {
		panic(err) // let the recovery middleware deal with this
	}
}

// GetIdentityEndpointsNotFoundCode is the HTTP code returned for type GetIdentityEndpointsNotFound
const GetIdentityEndpointsNotFoundCode int = 404

/*
GetIdentityEndpointsNotFound Set of identities which are being used by local endpoints could not be found.

swagger:response getIdentityEndpointsNotFound
*/
type GetIdentityEndpointsNotFound struct {
}

// NewGetIdentityEndpointsNotFound creates GetIdentityEndpointsNotFound with default headers values
func NewGetIdentityEndpointsNotFound() *GetIdentityEndpointsNotFound {

	return &GetIdentityEndpointsNotFound{}
}

// WriteResponse to the client
func (o *GetIdentityEndpointsNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer) {

	rw.Header().Del(runtime.HeaderContentType) //Remove Content-Type on empty responses

	rw.WriteHeader(404)
}
