// SetCidr sets the Cidr field's value.
196207
func (s *RouteFilterPrefix) SetCidr(v string) *RouteFilterPrefix {
	s.Cidr = &v
	return s
}
7298
func PatchNodeCIDR(c clientset.Interface, node types.NodeName, cidr string) error {
	raw, err := json.Marshal(cidr)
	if err != nil {
		return fmt.Errorf("failed to json.Marshal CIDR: %v", err)
	}

	patchBytes := []byte(fmt.Sprintf(`{"spec":{"podCIDR":%s}}`, raw))

	if _, err := c.CoreV1().Nodes().Patch(string(node), types.StrategicMergePatchType, patchBytes); err != nil {
		return fmt.Errorf("failed to patch node CIDR: %v", err)
	}
	return nil
}
1261590
func (o *GetFqdnCacheIDParams) bindCidr(rawData []string, hasKey bool, formats strfmt.Registry) error {
	var raw string
	if len(rawData) > 0 {
		raw = rawData[len(rawData)-1]
	}

	// Required: false
	// AllowEmptyValue: false
	if raw == "" { // empty values pass all other validations
		return nil
	}

	o.Cidr = &raw

	return nil
}
986970
func (s *RevokeDBSecurityGroupIngressInput) SetCIDRIP(v string) *RevokeDBSecurityGroupIngressInput {
	s.CIDRIP = &v
	return s
}
227
func (cm *CIDRMap) InsertCIDR(cidr net.IPNet) error {
	key := cm.cidrKeyInit(cidr)
	entry := [LPM_MAP_VALUE_SIZE]byte{}
	if err := cm.checkPrefixlen(&key, "update"); err != nil {
		return err
	}
	log.WithField(logfields.Path, cm.path).Debugf("Inserting CIDR entry %s", cidr.String())
	return bpf.UpdateElement(cm.Fd, unsafe.Pointer(&key), unsafe.Pointer(&entry), 0)
}
436927
func (s *DescribeAliasInput) SetAliasId(v string) *DescribeAliasInput {
	s.AliasId = &v
	return s
}
204270
func (s *CreateGameSessionInput) SetAliasId(v string) *CreateGameSessionInput {
	s.AliasId = &v
	return s
}
443197
func (s *ListCommandsInput) SetCommandId(v string) *ListCommandsInput {
	s.CommandId = &v
	return s
}
529021
func (s *CertificateDescription) SetCaCertificateId(v string) *CertificateDescription {
	s.CaCertificateId = &v
	return s
}
286823
func (s *CommentMetadata) SetRecipientId(v string) *CommentMetadata {
	s.RecipientId = &v
	return s
}
126643
func (kl *Kubelet) updatePodCIDR(cidr string) (bool, error) {
	kl.updatePodCIDRMux.Lock()
	defer kl.updatePodCIDRMux.Unlock()

	podCIDR := kl.runtimeState.podCIDR()

	if podCIDR == cidr {
		return false, nil
	}

	// kubelet -> generic runtime -> runtime shim -> network plugin
	// docker/non-cri implementations have a passthrough UpdatePodCIDR
	if err := kl.getRuntime().UpdatePodCIDR(cidr); err != nil {
		// If updatePodCIDR would fail, theoretically pod CIDR could not change.
		// But it is better to be on the safe side to still return true here.
		return true, fmt.Errorf("failed to update pod CIDR: %v", err)
	}

	klog.Infof("Setting Pod CIDR: %v -> %v", podCIDR, cidr)
	kl.runtimeState.setPodCIDR(cidr)
	return true, nil
}
495425
func (s *SearchGameSessionsInput) SetAliasId(v string) *SearchGameSessionsInput {
	s.AliasId = &v
	return s
}
250358
func (s *DvbSubSourceSettings) SetPid(v int64) *DvbSubSourceSettings {
	s.Pid = &v
	return s
}
51964
func (ab *dsAddrBook) SetAddr(p peer.ID, addr ma.Multiaddr, ttl time.Duration) {
	ab.SetAddrs(p, []ma.Multiaddr{addr}, ttl)
}
190743
func (s *DescribeCACertificateInput) SetCertificateId(v string) *DescribeCACertificateInput {
	s.CertificateId = &v
	return s
}
497823
func (mab *memoryAddrBook) SetAddr(p peer.ID, addr ma.Multiaddr, ttl time.Duration) {
	mab.SetAddrs(p, []ma.Multiaddr{addr}, ttl)
}
734062
func ParseCIDR(s string) (*CIDR, error) {
	_, net, err := net.ParseCIDR(s)
	if err != nil {
		return nil, err
	}
	return &CIDR{*net}, nil
}