// Copyright (c) 2026 Tigera, Inc. All rights reserved.

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

package v3

// IPReservationSpecApplyConfiguration represents a declarative configuration of the IPReservationSpec type for use
// with apply.
//
// IPReservationSpec contains the specification for an IPReservation resource.
type IPReservationSpecApplyConfiguration struct {
	// ReservedCIDRs is a list of CIDRs and/or IP addresses that Calico IPAM will exclude from new allocations.
	ReservedCIDRs []string `json:"reservedCIDRs,omitempty"`
}

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

// WithReservedCIDRs adds the given value to the ReservedCIDRs field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the ReservedCIDRs field.
func (b *IPReservationSpecApplyConfiguration) WithReservedCIDRs(values ...string) *IPReservationSpecApplyConfiguration {
	for i := range values {
		b.ReservedCIDRs = append(b.ReservedCIDRs, values[i])
	}
	return b
}
