// Copyright 2025 Antrea 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 v1beta2

import (
	context "context"

	controlplanev1beta2 "antrea.io/antrea/pkg/apis/controlplane/v1beta2"
	scheme "antrea.io/antrea/pkg/client/clientset/versioned/scheme"
	v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
	watch "k8s.io/apimachinery/pkg/watch"
	gentype "k8s.io/client-go/gentype"
)

// AppliedToGroupsGetter has a method to return a AppliedToGroupInterface.
// A group's client should implement this interface.
type AppliedToGroupsGetter interface {
	AppliedToGroups() AppliedToGroupInterface
}

// AppliedToGroupInterface has methods to work with AppliedToGroup resources.
type AppliedToGroupInterface interface {
	Get(ctx context.Context, name string, opts v1.GetOptions) (*controlplanev1beta2.AppliedToGroup, error)
	List(ctx context.Context, opts v1.ListOptions) (*controlplanev1beta2.AppliedToGroupList, error)
	Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
	AppliedToGroupExpansion
}

// appliedToGroups implements AppliedToGroupInterface
type appliedToGroups struct {
	*gentype.ClientWithList[*controlplanev1beta2.AppliedToGroup, *controlplanev1beta2.AppliedToGroupList]
}

// newAppliedToGroups returns a AppliedToGroups
func newAppliedToGroups(c *ControlplaneV1beta2Client) *appliedToGroups {
	return &appliedToGroups{
		gentype.NewClientWithList[*controlplanev1beta2.AppliedToGroup, *controlplanev1beta2.AppliedToGroupList](
			"appliedtogroups",
			c.RESTClient(),
			scheme.ParameterCodec,
			"",
			func() *controlplanev1beta2.AppliedToGroup { return &controlplanev1beta2.AppliedToGroup{} },
			func() *controlplanev1beta2.AppliedToGroupList { return &controlplanev1beta2.AppliedToGroupList{} },
		),
	}
}
