func (s statefulSetNamespaceLister) Get(name string) (*v1.StatefulSet, error) {
	obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
	if err != nil {
		return nil, err
	}
	if !exists {
		return nil, errors.NewNotFound(v1.Resource("statefulset"), name)
	}
	return obj.(*v1.StatefulSet), nil
}
Get retrieves the StatefulSet from the indexer for a given namespace and name.
package v1
import (
	v1 "k8s.io/api/apps/v1"
	"k8s.io/apimachinery/pkg/api/errors"
	"k8s.io/apimachinery/pkg/labels"
	"k8s.io/client-go/tools/cache"
)
type StatefulSetLister interface {
	List(selector labels.Selector) (ret []*v1.StatefulSet, err error)
	StatefulSets(namespace string) StatefulSetNamespaceLister
	StatefulSetListerExpansion
}
type statefulSetLister struct {
	indexer cache.Indexer
}
func NewStatefulSetLister(indexer cache.Indexer) StatefulSetLister {
	return &statefulSetLister{indexer: indexer}
}
func (s *statefulSetLister) List(selector labels.Selector) (ret []*v1.StatefulSet, err error) {
	err = cache.ListAll(s.indexer, selector, func(m interface{}) {
		ret = append(ret, m.(*v1.StatefulSet))
	})
	return ret, err
}
func (s *statefulSetLister) StatefulSets(namespace string) StatefulSetNamespaceLister {
	return statefulSetNamespaceLister{indexer: s.indexer, namespace: namespace}
}
type StatefulSetNamespaceLister interface {
	List(selector labels.Selector) (ret []*v1.StatefulSet, err error)
	Get(name string) (*v1.StatefulSet, error)
	StatefulSetNamespaceListerExpansion
}
type statefulSetNamespaceLister struct {
	indexer   cache.Indexer
	namespace string
}
func (s statefulSetNamespaceLister) List(selector labels.Selector) (ret []*v1.StatefulSet, err error) {
	err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
		ret = append(ret, m.(*v1.StatefulSet))
	})
	return ret, err
}