// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc             v5.29.0--rc2
// source: file-storage.proto

package filestorage

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

// FileStorageServiceClient is the client API for FileStorageService 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 FileStorageServiceClient interface {
	GetFile(ctx context.Context, in *GetFileRequest, opts ...grpc.CallOption) (*GetFileResponse, error)
}

type fileStorageServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewFileStorageServiceClient(cc grpc.ClientConnInterface) FileStorageServiceClient {
	return &fileStorageServiceClient{cc}
}

func (c *fileStorageServiceClient) GetFile(ctx context.Context, in *GetFileRequest, opts ...grpc.CallOption) (*GetFileResponse, error) {
	out := new(GetFileResponse)
	err := c.cc.Invoke(ctx, "/filestorage.FileStorageService/GetFile", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// FileStorageServiceServer is the server API for FileStorageService service.
// All implementations must embed UnimplementedFileStorageServiceServer
// for forward compatibility
type FileStorageServiceServer interface {
	GetFile(context.Context, *GetFileRequest) (*GetFileResponse, error)
	mustEmbedUnimplementedFileStorageServiceServer()
}

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

func (UnimplementedFileStorageServiceServer) GetFile(context.Context, *GetFileRequest) (*GetFileResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetFile not implemented")
}
func (UnimplementedFileStorageServiceServer) mustEmbedUnimplementedFileStorageServiceServer() {}

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

func RegisterFileStorageServiceServer(s grpc.ServiceRegistrar, srv FileStorageServiceServer) {
	s.RegisterService(&FileStorageService_ServiceDesc, srv)
}

func _FileStorageService_GetFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetFileRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(FileStorageServiceServer).GetFile(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/filestorage.FileStorageService/GetFile",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(FileStorageServiceServer).GetFile(ctx, req.(*GetFileRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// FileStorageService_ServiceDesc is the grpc.ServiceDesc for FileStorageService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var FileStorageService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "filestorage.FileStorageService",
	HandlerType: (*FileStorageServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetFile",
			Handler:    _FileStorageService_GetFile_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "file-storage.proto",
}
