Documentation
¶
Index ¶
- func NewAppProjectInformer(ctx context.Context, client appclientset.Interface, ...) (*informer.GenericInformer, applisters.AppProjectLister, error)
- type AppProjectInformer
- type AppProjectInformerOption
- func WithAddFunc(f func(proj *v1alpha1.AppProject)) AppProjectInformerOption
- func WithDeleteFunc(f func(proj *v1alpha1.AppProject)) AppProjectInformerOption
- func WithListFilter(f func(proj *v1alpha1.AppProject) bool) AppProjectInformerOption
- func WithLogger(l *logrus.Entry) AppProjectInformerOption
- func WithNamespaces(namespaces ...string) AppProjectInformerOption
- func WithUpdateFunc(f func(oldProj *v1alpha1.AppProject, newProj *v1alpha1.AppProject)) AppProjectInformerOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAppProjectInformer ¶
func NewAppProjectInformer(ctx context.Context, client appclientset.Interface, options ...AppProjectInformerOption) (*informer.GenericInformer, applisters.AppProjectLister, error)
NewAppProjectInformer returns a new instance of a GenericInformer set up to handle AppProjects. It will be configured with the given options, using the given appclientset.
Types ¶
type AppProjectInformer ¶
type AppProjectInformer struct {
// contains filtered or unexported fields
}
type AppProjectInformerOption ¶
type AppProjectInformerOption func(pi *AppProjectInformer) error
func WithAddFunc ¶
func WithAddFunc(f func(proj *v1alpha1.AppProject)) AppProjectInformerOption
WithAddFunc sets the function to be called when an AppProject is created on the cluster.
func WithDeleteFunc ¶
func WithDeleteFunc(f func(proj *v1alpha1.AppProject)) AppProjectInformerOption
WithDeleteFunc sets the function to be called when an AppProject is deleted on the cluster.
func WithListFilter ¶
func WithListFilter(f func(proj *v1alpha1.AppProject) bool) AppProjectInformerOption
WithListFilter sets a filter function for the add, update and delete events. This function will be called for each event, and if it returns false, the event's execution will not continue.
func WithLogger ¶
func WithLogger(l *logrus.Entry) AppProjectInformerOption
WithLogger sets the logger to use with this AppProjectInformer
func WithNamespaces ¶
func WithNamespaces(namespaces ...string) AppProjectInformerOption
WithNamespaces restricts the informer to certain namespaces. If no namespace is set, or if multiple are set, the informer requires cluster-wide access to AppProjects. When one or more namespaces are set, only objects in these namespaces will be considered by the informer.
func WithUpdateFunc ¶
func WithUpdateFunc(f func(oldProj *v1alpha1.AppProject, newProj *v1alpha1.AppProject)) AppProjectInformerOption
WithUpdateFunc sets the function to be called when an AppProject is updated on the cluster.