// Copyright Contributors to the Open Cluster Management project
// Code generated by lister-gen. DO NOT EDIT.

package v1beta1

import (
	labels "k8s.io/apimachinery/pkg/labels"
	listers "k8s.io/client-go/listers"
	cache "k8s.io/client-go/tools/cache"
	clusterv1beta1 "open-cluster-management.io/api/cluster/v1beta1"
)

// PlacementDecisionLister helps list PlacementDecisions.
// All objects returned here must be treated as read-only.
type PlacementDecisionLister interface {
	// List lists all PlacementDecisions in the indexer.
	// Objects returned here must be treated as read-only.
	List(selector labels.Selector) (ret []*clusterv1beta1.PlacementDecision, err error)
	// PlacementDecisions returns an object that can list and get PlacementDecisions.
	PlacementDecisions(namespace string) PlacementDecisionNamespaceLister
	PlacementDecisionListerExpansion
}

// placementDecisionLister implements the PlacementDecisionLister interface.
type placementDecisionLister struct {
	listers.ResourceIndexer[*clusterv1beta1.PlacementDecision]
}

// NewPlacementDecisionLister returns a new PlacementDecisionLister.
func NewPlacementDecisionLister(indexer cache.Indexer) PlacementDecisionLister {
	return &placementDecisionLister{listers.New[*clusterv1beta1.PlacementDecision](indexer, clusterv1beta1.Resource("placementdecision"))}
}

// PlacementDecisions returns an object that can list and get PlacementDecisions.
func (s *placementDecisionLister) PlacementDecisions(namespace string) PlacementDecisionNamespaceLister {
	return placementDecisionNamespaceLister{listers.NewNamespaced[*clusterv1beta1.PlacementDecision](s.ResourceIndexer, namespace)}
}

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

// placementDecisionNamespaceLister implements the PlacementDecisionNamespaceLister
// interface.
type placementDecisionNamespaceLister struct {
	listers.ResourceIndexer[*clusterv1beta1.PlacementDecision]
}
