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

// Copyright 2019 HAProxy Technologies
//
// 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
//
//     http://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.
//

package acl_runtime

// 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/haproxytech/client-native/v6/models"
)

// GetServicesHaproxyRuntimeAclsParentNameEntriesIDOKCode is the HTTP code returned for type GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK
const GetServicesHaproxyRuntimeAclsParentNameEntriesIDOKCode int = 200

/*
GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK Successful operation

swagger:response getServicesHaproxyRuntimeAclsParentNameEntriesIdOK
*/
type GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK struct {

	/*
	  In: Body
	*/
	Payload *models.ACLFileEntry `json:"body,omitempty"`
}

// NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDOK creates GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK with default headers values
func NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDOK() *GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK {

	return &GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK{}
}

// WithPayload adds the payload to the get services haproxy runtime acls parent name entries Id o k response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK) WithPayload(payload *models.ACLFileEntry) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the get services haproxy runtime acls parent name entries Id o k response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK) SetPayload(payload *models.ACLFileEntry) {
	o.Payload = payload
}

// WriteResponse to the client
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDOK) 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
		}
	}
}

// GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequestCode is the HTTP code returned for type GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest
const GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequestCode int = 400

/*
GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest Bad request

swagger:response getServicesHaproxyRuntimeAclsParentNameEntriesIdBadRequest
*/
type GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest struct {
	/*Configuration file version

	 */
	ConfigurationVersion string `json:"Configuration-Version"`

	/*
	  In: Body
	*/
	Payload *models.Error `json:"body,omitempty"`
}

// NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest creates GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest with default headers values
func NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest() *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest {

	return &GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest{}
}

// WithConfigurationVersion adds the configurationVersion to the get services haproxy runtime acls parent name entries Id bad request response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest) WithConfigurationVersion(configurationVersion string) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest {
	o.ConfigurationVersion = configurationVersion
	return o
}

// SetConfigurationVersion sets the configurationVersion to the get services haproxy runtime acls parent name entries Id bad request response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest) SetConfigurationVersion(configurationVersion string) {
	o.ConfigurationVersion = configurationVersion
}

// WithPayload adds the payload to the get services haproxy runtime acls parent name entries Id bad request response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest) WithPayload(payload *models.Error) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the get services haproxy runtime acls parent name entries Id bad request response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDBadRequest) SetPayload(payload *models.Error) {
	o.Payload = payload
}

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

	// response header Configuration-Version

	configurationVersion := o.ConfigurationVersion
	if configurationVersion != "" {
		rw.Header().Set("Configuration-Version", configurationVersion)
	}

	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
		}
	}
}

// GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFoundCode is the HTTP code returned for type GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound
const GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFoundCode int = 404

/*
GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound The specified resource was not found

swagger:response getServicesHaproxyRuntimeAclsParentNameEntriesIdNotFound
*/
type GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound struct {
	/*Configuration file version

	 */
	ConfigurationVersion string `json:"Configuration-Version"`

	/*
	  In: Body
	*/
	Payload *models.Error `json:"body,omitempty"`
}

// NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound creates GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound with default headers values
func NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound() *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound {

	return &GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound{}
}

// WithConfigurationVersion adds the configurationVersion to the get services haproxy runtime acls parent name entries Id not found response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound) WithConfigurationVersion(configurationVersion string) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound {
	o.ConfigurationVersion = configurationVersion
	return o
}

// SetConfigurationVersion sets the configurationVersion to the get services haproxy runtime acls parent name entries Id not found response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound) SetConfigurationVersion(configurationVersion string) {
	o.ConfigurationVersion = configurationVersion
}

// WithPayload adds the payload to the get services haproxy runtime acls parent name entries Id not found response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound) WithPayload(payload *models.Error) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the get services haproxy runtime acls parent name entries Id not found response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDNotFound) SetPayload(payload *models.Error) {
	o.Payload = payload
}

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

	// response header Configuration-Version

	configurationVersion := o.ConfigurationVersion
	if configurationVersion != "" {
		rw.Header().Set("Configuration-Version", configurationVersion)
	}

	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
		}
	}
}

/*
GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault General Error

swagger:response getServicesHaproxyRuntimeAclsParentNameEntriesIdDefault
*/
type GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault struct {
	_statusCode int
	/*Configuration file version

	 */
	ConfigurationVersion string `json:"Configuration-Version"`

	/*
	  In: Body
	*/
	Payload *models.Error `json:"body,omitempty"`
}

// NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault creates GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault with default headers values
func NewGetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault(code int) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault {
	if code <= 0 {
		code = 500
	}

	return &GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault{
		_statusCode: code,
	}
}

// WithStatusCode adds the status to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) WithStatusCode(code int) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault {
	o._statusCode = code
	return o
}

// SetStatusCode sets the status to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) SetStatusCode(code int) {
	o._statusCode = code
}

// WithConfigurationVersion adds the configurationVersion to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) WithConfigurationVersion(configurationVersion string) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault {
	o.ConfigurationVersion = configurationVersion
	return o
}

// SetConfigurationVersion sets the configurationVersion to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) SetConfigurationVersion(configurationVersion string) {
	o.ConfigurationVersion = configurationVersion
}

// WithPayload adds the payload to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) WithPayload(payload *models.Error) *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault {
	o.Payload = payload
	return o
}

// SetPayload sets the payload to the get services haproxy runtime acls parent name entries ID default response
func (o *GetServicesHaproxyRuntimeAclsParentNameEntriesIDDefault) SetPayload(payload *models.Error) {
	o.Payload = payload
}

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

	// response header Configuration-Version

	configurationVersion := o.ConfigurationVersion
	if configurationVersion != "" {
		rw.Header().Set("Configuration-Version", configurationVersion)
	}

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