func NewFilteredJobSetInformer()

in client-go/informers/externalversions/jobset/v1alpha1/jobset.go [54:74]


func NewFilteredJobSetInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
	return cache.NewSharedIndexInformer(
		&cache.ListWatch{
			ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
				if tweakListOptions != nil {
					tweakListOptions(&options)
				}
				return client.JobsetV1alpha1().JobSets(namespace).List(context.TODO(), options)
			},
			WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
				if tweakListOptions != nil {
					tweakListOptions(&options)
				}
				return client.JobsetV1alpha1().JobSets(namespace).Watch(context.TODO(), options)
			},
		},
		&jobsetv1alpha1.JobSet{},
		resyncPeriod,
		indexers,
	)
}