// Code generated by protoc-gen-go-grpc. DO NOT EDIT.

package protos

import (
	context "context"

	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.32.0 or later.
const _ = grpc.SupportPackageIsVersion7

// AuthRpcServiceClient is the client API for AuthRpcService 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.
type AuthRpcServiceClient interface {
	ValidateRequest(ctx context.Context, in *ValidationRequest, opts ...grpc.CallOption) (*ValidationResponse, error)
	GetProjectById(ctx context.Context, in *GetProjectByIdRequest, opts ...grpc.CallOption) (*GetProjectByIdResponse, error)
}

type authRpcServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewAuthRpcServiceClient(cc grpc.ClientConnInterface) AuthRpcServiceClient {
	return &authRpcServiceClient{cc}
}

func (c *authRpcServiceClient) ValidateRequest(ctx context.Context, in *ValidationRequest, opts ...grpc.CallOption) (*ValidationResponse, error) {
	out := new(ValidationResponse)
	err := c.cc.Invoke(ctx, "/protos.authRpcService/ValidateRequest", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *authRpcServiceClient) GetProjectById(ctx context.Context, in *GetProjectByIdRequest, opts ...grpc.CallOption) (*GetProjectByIdResponse, error) {
	out := new(GetProjectByIdResponse)
	err := c.cc.Invoke(ctx, "/protos.authRpcService/GetProjectById", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// AuthRpcServiceServer is the server API for AuthRpcService service.
// All implementations must embed UnimplementedAuthRpcServiceServer
// for forward compatibility
type AuthRpcServiceServer interface {
	ValidateRequest(context.Context, *ValidationRequest) (*ValidationResponse, error)
	GetProjectById(context.Context, *GetProjectByIdRequest) (*GetProjectByIdResponse, error)
	mustEmbedUnimplementedAuthRpcServiceServer()
}

// UnimplementedAuthRpcServiceServer must be embedded to have forward compatible implementations.
type UnimplementedAuthRpcServiceServer struct {
}

func (UnimplementedAuthRpcServiceServer) ValidateRequest(context.Context, *ValidationRequest) (*ValidationResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ValidateRequest not implemented")
}
func (UnimplementedAuthRpcServiceServer) GetProjectById(context.Context, *GetProjectByIdRequest) (*GetProjectByIdResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetProjectById not implemented")
}
func (UnimplementedAuthRpcServiceServer) mustEmbedUnimplementedAuthRpcServiceServer() {}

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

func RegisterAuthRpcServiceServer(s grpc.ServiceRegistrar, srv AuthRpcServiceServer) {
	s.RegisterService(&AuthRpcService_ServiceDesc, srv)
}

func _AuthRpcService_ValidateRequest_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ValidationRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AuthRpcServiceServer).ValidateRequest(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/protos.authRpcService/ValidateRequest",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AuthRpcServiceServer).ValidateRequest(ctx, req.(*ValidationRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _AuthRpcService_GetProjectById_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetProjectByIdRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(AuthRpcServiceServer).GetProjectById(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/protos.authRpcService/GetProjectById",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(AuthRpcServiceServer).GetProjectById(ctx, req.(*GetProjectByIdRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// AuthRpcService_ServiceDesc is the grpc.ServiceDesc for AuthRpcService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var AuthRpcService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "protos.authRpcService",
	HandlerType: (*AuthRpcServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "ValidateRequest",
			Handler:    _AuthRpcService_ValidateRequest_Handler,
		},
		{
			MethodName: "GetProjectById",
			Handler:    _AuthRpcService_GetProjectById_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "authentication.proto",
}
