- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for DepthFirstWalk (0.14 sec)
-
pkg/util/iptree/iptree.go
func (t *Tree[T]) Len(isV6 bool) int { count := 0 t.DepthFirstWalk(isV6, func(k netip.Prefix, v T) bool { count++ return false }) return count } // WalkFn is used when walking the tree. Takes a // key and value, returning if iteration should // be terminated. type WalkFn[T any] func(s netip.Prefix, v T) bool // DepthFirstWalk is used to walk the tree of the corresponding IP family
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Oct 31 21:05:04 UTC 2023 - 17.7K bytes - Viewed (0) -
pkg/registry/core/service/ipallocator/cidrallocator.go
cidrsSet.Insert(cidr) cidrReady[cidr] = ready } } } // obtain the existing allocators and set the existing state treeSet := sets.New[string]() c.muTree.Lock() c.tree.DepthFirstWalk(c.ipFamily == api.IPv6Protocol, func(k netip.Prefix, v *Allocator) bool { v.ready.Store(cidrReady[k.String()]) treeSet.Insert(k.String()) return false }) c.muTree.Unlock()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 04 18:33:12 UTC 2024 - 13.2K bytes - Viewed (0)