/*
Copyright The Kubernetes Authors.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

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

package fake

import (
	v1alpha2 "k8s.io/api/coordination/v1alpha2"
	coordinationv1alpha2 "k8s.io/client-go/applyconfigurations/coordination/v1alpha2"
	gentype "k8s.io/client-go/gentype"
	typedcoordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2"
)

// fakeLeaseCandidates implements LeaseCandidateInterface
type fakeLeaseCandidates struct {
	*gentype.FakeClientWithListAndApply[*v1alpha2.LeaseCandidate, *v1alpha2.LeaseCandidateList, *coordinationv1alpha2.LeaseCandidateApplyConfiguration]
	Fake *FakeCoordinationV1alpha2
}

func newFakeLeaseCandidates(fake *FakeCoordinationV1alpha2, namespace string) typedcoordinationv1alpha2.LeaseCandidateInterface {
	return &fakeLeaseCandidates{
		gentype.NewFakeClientWithListAndApply[*v1alpha2.LeaseCandidate, *v1alpha2.LeaseCandidateList, *coordinationv1alpha2.LeaseCandidateApplyConfiguration](
			fake.Fake,
			namespace,
			v1alpha2.SchemeGroupVersion.WithResource("leasecandidates"),
			v1alpha2.SchemeGroupVersion.WithKind("LeaseCandidate"),
			func() *v1alpha2.LeaseCandidate { return &v1alpha2.LeaseCandidate{} },
			func() *v1alpha2.LeaseCandidateList { return &v1alpha2.LeaseCandidateList{} },
			func(dst, src *v1alpha2.LeaseCandidateList) { dst.ListMeta = src.ListMeta },
			func(list *v1alpha2.LeaseCandidateList) []*v1alpha2.LeaseCandidate {
				return gentype.ToPointerSlice(list.Items)
			},
			func(list *v1alpha2.LeaseCandidateList, items []*v1alpha2.LeaseCandidate) {
				list.Items = gentype.FromPointerSlice(items)
			},
		),
		fake,
	}
}
