func()

in internal/filter/items/items.go [44:58]


func (i Item) IsState(c Object) Age {
	// If the resource version is the same, then the item is equal.
	if i.ResourceVersion == c.GetResourceVersion() {
		return Equal
	}
	switch {
	case i.Generation > c.GetGeneration():
		return Newer
	case i.Generation < c.GetGeneration():
		return Older
	case i.Generation == c.GetGeneration():
		return Equal
	}
	panic("unreachable")
}