// Code generated by applyconfiguration-gen. DO NOT EDIT.

package v1

import (
	operatorv1 "github.com/openshift/api/operator/v1"
)

// NoOverlayConfigApplyConfiguration represents a declarative configuration of the NoOverlayConfig type for use
// with apply.
//
// NoOverlayConfig contains configuration options for networks operating in no-overlay mode.
type NoOverlayConfigApplyConfiguration struct {
	// outboundSNAT defines the SNAT behavior for outbound traffic from pods.
	// Allowed values are "Enabled" and "Disabled".
	// When set to "Enabled", SNAT is performed on outbound traffic from pods.
	// When set to "Disabled", SNAT is not performed and pod IPs are preserved in outbound traffic.
	// This field is required when the network operates in no-overlay mode.
	// This field can be set to any value at installation time and can be changed afterwards.
	OutboundSNAT *operatorv1.SNATOption `json:"outboundSNAT,omitempty"`
	// routing specifies whether the pod network routing is managed by OVN-Kubernetes or users.
	// Allowed values are "Managed" and "Unmanaged".
	// When set to "Managed", OVN-Kubernetes manages the pod network routing configuration through BGP.
	// When set to "Unmanaged", users are responsible for configuring the pod network routing.
	// This field is required when the network operates in no-overlay mode.
	// This field is immutable once set.
	Routing *operatorv1.RoutingOption `json:"routing,omitempty"`
}

// NoOverlayConfigApplyConfiguration constructs a declarative configuration of the NoOverlayConfig type for use with
// apply.
func NoOverlayConfig() *NoOverlayConfigApplyConfiguration {
	return &NoOverlayConfigApplyConfiguration{}
}

// WithOutboundSNAT sets the OutboundSNAT field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the OutboundSNAT field is set to the value of the last call.
func (b *NoOverlayConfigApplyConfiguration) WithOutboundSNAT(value operatorv1.SNATOption) *NoOverlayConfigApplyConfiguration {
	b.OutboundSNAT = &value
	return b
}

// WithRouting sets the Routing field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Routing field is set to the value of the last call.
func (b *NoOverlayConfigApplyConfiguration) WithRouting(value operatorv1.RoutingOption) *NoOverlayConfigApplyConfiguration {
	b.Routing = &value
	return b
}
