// Copyright 2020-2026 the Pinniped contributors. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0

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

package v1alpha1

import (
	configv1alpha1 "go.pinniped.dev/generated/1.32/apis/supervisor/config/v1alpha1"
	labels "k8s.io/apimachinery/pkg/labels"
	listers "k8s.io/client-go/listers"
	cache "k8s.io/client-go/tools/cache"
)

// FederationDomainLister helps list FederationDomains.
// All objects returned here must be treated as read-only.
type FederationDomainLister interface {
	// List lists all FederationDomains in the indexer.
	// Objects returned here must be treated as read-only.
	List(selector labels.Selector) (ret []*configv1alpha1.FederationDomain, err error)
	// FederationDomains returns an object that can list and get FederationDomains.
	FederationDomains(namespace string) FederationDomainNamespaceLister
	FederationDomainListerExpansion
}

// federationDomainLister implements the FederationDomainLister interface.
type federationDomainLister struct {
	listers.ResourceIndexer[*configv1alpha1.FederationDomain]
}

// NewFederationDomainLister returns a new FederationDomainLister.
func NewFederationDomainLister(indexer cache.Indexer) FederationDomainLister {
	return &federationDomainLister{listers.New[*configv1alpha1.FederationDomain](indexer, configv1alpha1.Resource("federationdomain"))}
}

// FederationDomains returns an object that can list and get FederationDomains.
func (s *federationDomainLister) FederationDomains(namespace string) FederationDomainNamespaceLister {
	return federationDomainNamespaceLister{listers.NewNamespaced[*configv1alpha1.FederationDomain](s.ResourceIndexer, namespace)}
}

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

// federationDomainNamespaceLister implements the FederationDomainNamespaceLister
// interface.
type federationDomainNamespaceLister struct {
	listers.ResourceIndexer[*configv1alpha1.FederationDomain]
}
