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

package v1

// ClusterNetworkEntryApplyConfiguration represents a declarative configuration of the ClusterNetworkEntry type for use
// with apply.
//
// ClusterNetworkEntry is a subnet from which to allocate PodIPs. A network of size
// HostPrefix (in CIDR notation) will be allocated when nodes join the cluster. If
// the HostPrefix field is not used by the plugin, it can be left unset.
// Not all network providers support multiple ClusterNetworks
type ClusterNetworkEntryApplyConfiguration struct {
	CIDR       *string `json:"cidr,omitempty"`
	HostPrefix *uint32 `json:"hostPrefix,omitempty"`
}

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

// WithCIDR sets the CIDR 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 CIDR field is set to the value of the last call.
func (b *ClusterNetworkEntryApplyConfiguration) WithCIDR(value string) *ClusterNetworkEntryApplyConfiguration {
	b.CIDR = &value
	return b
}

// WithHostPrefix sets the HostPrefix 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 HostPrefix field is set to the value of the last call.
func (b *ClusterNetworkEntryApplyConfiguration) WithHostPrefix(value uint32) *ClusterNetworkEntryApplyConfiguration {
	b.HostPrefix = &value
	return b
}
