// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.5.1
// - protoc             v3.21.12
// source: yandex/cloud/smartwebsecurity/v1/advanced_rate_limiter/advanced_rate_limiter_profile_service.proto

package smartwebsecurity

import (
	context "context"
	operation "github.com/yandex-cloud/go-genproto/yandex/cloud/operation"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
)

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.64.0 or later.
const _ = grpc.SupportPackageIsVersion9

const (
	AdvancedRateLimiterProfileService_Get_FullMethodName    = "/yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService/Get"
	AdvancedRateLimiterProfileService_List_FullMethodName   = "/yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService/List"
	AdvancedRateLimiterProfileService_Create_FullMethodName = "/yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService/Create"
	AdvancedRateLimiterProfileService_Update_FullMethodName = "/yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService/Update"
	AdvancedRateLimiterProfileService_Delete_FullMethodName = "/yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService/Delete"
)

// AdvancedRateLimiterProfileServiceClient is the client API for AdvancedRateLimiterProfileService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
//
// A set of methods for managing AdvancedRateLimiterProfile resources.
type AdvancedRateLimiterProfileServiceClient interface {
	// Returns the specified AdvancedRateLimiterProfile resource.
	Get(ctx context.Context, in *GetAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*AdvancedRateLimiterProfile, error)
	// Retrieves the list of AdvancedRateLimiterProfile resources in the specified folder.
	List(ctx context.Context, in *ListAdvancedRateLimiterProfilesRequest, opts ...grpc.CallOption) (*ListAdvancedRateLimiterProfilesResponse, error)
	// Creates a ARL profile in the specified folder using the data specified in the request.
	Create(ctx context.Context, in *CreateAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Updates the specified ARL profile.
	Update(ctx context.Context, in *UpdateAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error)
	// Deletes the specified ARL profile.
	Delete(ctx context.Context, in *DeleteAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error)
}

type advancedRateLimiterProfileServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewAdvancedRateLimiterProfileServiceClient(cc grpc.ClientConnInterface) AdvancedRateLimiterProfileServiceClient {
	return &advancedRateLimiterProfileServiceClient{cc}
}

func (c *advancedRateLimiterProfileServiceClient) Get(ctx context.Context, in *GetAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*AdvancedRateLimiterProfile, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(AdvancedRateLimiterProfile)
	err := c.cc.Invoke(ctx, AdvancedRateLimiterProfileService_Get_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *advancedRateLimiterProfileServiceClient) List(ctx context.Context, in *ListAdvancedRateLimiterProfilesRequest, opts ...grpc.CallOption) (*ListAdvancedRateLimiterProfilesResponse, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(ListAdvancedRateLimiterProfilesResponse)
	err := c.cc.Invoke(ctx, AdvancedRateLimiterProfileService_List_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *advancedRateLimiterProfileServiceClient) Create(ctx context.Context, in *CreateAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, AdvancedRateLimiterProfileService_Create_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *advancedRateLimiterProfileServiceClient) Update(ctx context.Context, in *UpdateAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, AdvancedRateLimiterProfileService_Update_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *advancedRateLimiterProfileServiceClient) Delete(ctx context.Context, in *DeleteAdvancedRateLimiterProfileRequest, opts ...grpc.CallOption) (*operation.Operation, error) {
	cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
	out := new(operation.Operation)
	err := c.cc.Invoke(ctx, AdvancedRateLimiterProfileService_Delete_FullMethodName, in, out, cOpts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// AdvancedRateLimiterProfileServiceServer is the server API for AdvancedRateLimiterProfileService service.
// All implementations should embed UnimplementedAdvancedRateLimiterProfileServiceServer
// for forward compatibility.
//
// A set of methods for managing AdvancedRateLimiterProfile resources.
type AdvancedRateLimiterProfileServiceServer interface {
	// Returns the specified AdvancedRateLimiterProfile resource.
	Get(context.Context, *GetAdvancedRateLimiterProfileRequest) (*AdvancedRateLimiterProfile, error)
	// Retrieves the list of AdvancedRateLimiterProfile resources in the specified folder.
	List(context.Context, *ListAdvancedRateLimiterProfilesRequest) (*ListAdvancedRateLimiterProfilesResponse, error)
	// Creates a ARL profile in the specified folder using the data specified in the request.
	Create(context.Context, *CreateAdvancedRateLimiterProfileRequest) (*operation.Operation, error)
	// Updates the specified ARL profile.
	Update(context.Context, *UpdateAdvancedRateLimiterProfileRequest) (*operation.Operation, error)
	// Deletes the specified ARL profile.
	Delete(context.Context, *DeleteAdvancedRateLimiterProfileRequest) (*operation.Operation, error)
}

// UnimplementedAdvancedRateLimiterProfileServiceServer should be embedded to have
// forward compatible implementations.
//
// NOTE: this should be embedded by value instead of pointer to avoid a nil
// pointer dereference when methods are called.
type UnimplementedAdvancedRateLimiterProfileServiceServer struct{}

func (UnimplementedAdvancedRateLimiterProfileServiceServer) Get(context.Context, *GetAdvancedRateLimiterProfileRequest) (*AdvancedRateLimiterProfile, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Get not implemented")
}
func (UnimplementedAdvancedRateLimiterProfileServiceServer) List(context.Context, *ListAdvancedRateLimiterProfilesRequest) (*ListAdvancedRateLimiterProfilesResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method List not implemented")
}
func (UnimplementedAdvancedRateLimiterProfileServiceServer) Create(context.Context, *CreateAdvancedRateLimiterProfileRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Create not implemented")
}
func (UnimplementedAdvancedRateLimiterProfileServiceServer) Update(context.Context, *UpdateAdvancedRateLimiterProfileRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Update not implemented")
}
func (UnimplementedAdvancedRateLimiterProfileServiceServer) Delete(context.Context, *DeleteAdvancedRateLimiterProfileRequest) (*operation.Operation, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Delete not implemented")
}
func (UnimplementedAdvancedRateLimiterProfileServiceServer) testEmbeddedByValue() {}

// UnsafeAdvancedRateLimiterProfileServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to AdvancedRateLimiterProfileServiceServer will
// result in compilation errors.
type UnsafeAdvancedRateLimiterProfileServiceServer interface {
	mustEmbedUnimplementedAdvancedRateLimiterProfileServiceServer()
}

func RegisterAdvancedRateLimiterProfileServiceServer(s grpc.ServiceRegistrar, srv AdvancedRateLimiterProfileServiceServer) {
	// If the following call pancis, it indicates UnimplementedAdvancedRateLimiterProfileServiceServer was
	// embedded by pointer and is nil.  This will cause panics if an
	// unimplemented method is ever invoked, so we test this at initialization
	// time to prevent it from happening at runtime later due to I/O.
	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok {
		t.testEmbeddedByValue()
	}
	s.RegisterService(&AdvancedRateLimiterProfileService_ServiceDesc, srv)
}

func _AdvancedRateLimiterProfileService_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetAdvancedRateLimiterProfileRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AdvancedRateLimiterProfileServiceServer).Get(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AdvancedRateLimiterProfileService_Get_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AdvancedRateLimiterProfileServiceServer).Get(ctx, req.(*GetAdvancedRateLimiterProfileRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AdvancedRateLimiterProfileService_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListAdvancedRateLimiterProfilesRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AdvancedRateLimiterProfileServiceServer).List(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AdvancedRateLimiterProfileService_List_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AdvancedRateLimiterProfileServiceServer).List(ctx, req.(*ListAdvancedRateLimiterProfilesRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AdvancedRateLimiterProfileService_Create_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CreateAdvancedRateLimiterProfileRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AdvancedRateLimiterProfileServiceServer).Create(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AdvancedRateLimiterProfileService_Create_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AdvancedRateLimiterProfileServiceServer).Create(ctx, req.(*CreateAdvancedRateLimiterProfileRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AdvancedRateLimiterProfileService_Update_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(UpdateAdvancedRateLimiterProfileRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AdvancedRateLimiterProfileServiceServer).Update(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AdvancedRateLimiterProfileService_Update_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AdvancedRateLimiterProfileServiceServer).Update(ctx, req.(*UpdateAdvancedRateLimiterProfileRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AdvancedRateLimiterProfileService_Delete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(DeleteAdvancedRateLimiterProfileRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AdvancedRateLimiterProfileServiceServer).Delete(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: AdvancedRateLimiterProfileService_Delete_FullMethodName,
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AdvancedRateLimiterProfileServiceServer).Delete(ctx, req.(*DeleteAdvancedRateLimiterProfileRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// AdvancedRateLimiterProfileService_ServiceDesc is the grpc.ServiceDesc for AdvancedRateLimiterProfileService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var AdvancedRateLimiterProfileService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "yandex.cloud.smartwebsecurity.v1.advanced_rate_limiter.AdvancedRateLimiterProfileService",
	HandlerType: (*AdvancedRateLimiterProfileServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Get",
			Handler:    _AdvancedRateLimiterProfileService_Get_Handler,
		},
		{
			MethodName: "List",
			Handler:    _AdvancedRateLimiterProfileService_List_Handler,
		},
		{
			MethodName: "Create",
			Handler:    _AdvancedRateLimiterProfileService_Create_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _AdvancedRateLimiterProfileService_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _AdvancedRateLimiterProfileService_Delete_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "yandex/cloud/smartwebsecurity/v1/advanced_rate_limiter/advanced_rate_limiter_profile_service.proto",
}
