listwatch

package
v0.0.0-...-cdd6034 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 19, 2024 License: BSD-3-Clause, Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsAllNamespaces

func IsAllNamespaces(namespaces []string) bool

IsAllNamespaces checks if the given slice of namespaces contains only v1.NamespaceAll.

func MultiNamespaceListerWatcher

func MultiNamespaceListerWatcher(namespaces []string, f func(string) cache.ListerWatcher) cache.ListerWatcher

MultiNamespaceListerWatcher takes a list of namespaces and a cache.ListerWatcher generator func and returns a single cache.ListerWatcher capable of operating on multiple namespaces.

func NewFilteredUnprivilegedNamespaceListWatchFromClient

func NewFilteredUnprivilegedNamespaceListWatchFromClient(c cache.Getter, namespaces []string, optionsModifier func(options *metav1.ListOptions)) *cache.ListWatch

NewFilteredUnprivilegedNamespaceListWatchFromClient mimics cache.NewUnprivilegedNamespaceListWatchFromClient. It allows for the creation of a cache.ListWatch for namespaces from a client that does not have `List` privileges. If the slice of namespaces contains only v1.NamespaceAll, then this func assumes that the client has List and Watch privileges and returns a regular cache.ListWatch, since there is no other way to get all namespaces.

func NewUnprivilegedNamespaceListWatchFromClient

func NewUnprivilegedNamespaceListWatchFromClient(c cache.Getter, namespaces []string, fieldSelector fields.Selector) *cache.ListWatch

NewUnprivilegedNamespaceListWatchFromClient mimics cache.NewListWatchFromClient. It allows for the creation of a cache.ListWatch for namespaces from a client that does not have `List` privileges. If the slice of namespaces contains only v1.NamespaceAll, then this func assumes that the client has List and Watch privileges and returns a regular cache.ListWatch, since there is no other way to get all namespaces.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL