// Code generated by lister-gen. DO NOT EDIT.

package v1

import (
	machinev1 "github.com/openshift/api/machine/v1"
	labels "k8s.io/apimachinery/pkg/labels"
	listers "k8s.io/client-go/listers"
	cache "k8s.io/client-go/tools/cache"
)

// ControlPlaneMachineSetLister helps list ControlPlaneMachineSets.
// All objects returned here must be treated as read-only.
type ControlPlaneMachineSetLister interface {
	// List lists all ControlPlaneMachineSets in the indexer.
	// Objects returned here must be treated as read-only.
	List(selector labels.Selector) (ret []*machinev1.ControlPlaneMachineSet, err error)
	// ControlPlaneMachineSets returns an object that can list and get ControlPlaneMachineSets.
	ControlPlaneMachineSets(namespace string) ControlPlaneMachineSetNamespaceLister
	ControlPlaneMachineSetListerExpansion
}

// controlPlaneMachineSetLister implements the ControlPlaneMachineSetLister interface.
type controlPlaneMachineSetLister struct {
	listers.ResourceIndexer[*machinev1.ControlPlaneMachineSet]
}

// NewControlPlaneMachineSetLister returns a new ControlPlaneMachineSetLister.
func NewControlPlaneMachineSetLister(indexer cache.Indexer) ControlPlaneMachineSetLister {
	return &controlPlaneMachineSetLister{listers.New[*machinev1.ControlPlaneMachineSet](indexer, machinev1.Resource("controlplanemachineset"))}
}

// ControlPlaneMachineSets returns an object that can list and get ControlPlaneMachineSets.
func (s *controlPlaneMachineSetLister) ControlPlaneMachineSets(namespace string) ControlPlaneMachineSetNamespaceLister {
	return controlPlaneMachineSetNamespaceLister{listers.NewNamespaced[*machinev1.ControlPlaneMachineSet](s.ResourceIndexer, namespace)}
}

// ControlPlaneMachineSetNamespaceLister helps list and get ControlPlaneMachineSets.
// All objects returned here must be treated as read-only.
type ControlPlaneMachineSetNamespaceLister interface {
	// List lists all ControlPlaneMachineSets in the indexer for a given namespace.
	// Objects returned here must be treated as read-only.
	List(selector labels.Selector) (ret []*machinev1.ControlPlaneMachineSet, err error)
	// Get retrieves the ControlPlaneMachineSet from the indexer for a given namespace and name.
	// Objects returned here must be treated as read-only.
	Get(name string) (*machinev1.ControlPlaneMachineSet, error)
	ControlPlaneMachineSetNamespaceListerExpansion
}

// controlPlaneMachineSetNamespaceLister implements the ControlPlaneMachineSetNamespaceLister
// interface.
type controlPlaneMachineSetNamespaceLister struct {
	listers.ResourceIndexer[*machinev1.ControlPlaneMachineSet]
}
