# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""
import grpc

from ydb._grpc.v3.protos import ydb_export_pb2 as protos_dot_ydb__export__pb2


class ExportServiceStub(object):
    """Missing associated documentation comment in .proto file."""

    def __init__(self, channel):
        """Constructor.

        Args:
            channel: A grpc.Channel.
        """
        self.ExportToYt = channel.unary_unary(
                '/Ydb.Export.V1.ExportService/ExportToYt',
                request_serializer=protos_dot_ydb__export__pb2.ExportToYtRequest.SerializeToString,
                response_deserializer=protos_dot_ydb__export__pb2.ExportToYtResponse.FromString,
                )
        self.ExportToS3 = channel.unary_unary(
                '/Ydb.Export.V1.ExportService/ExportToS3',
                request_serializer=protos_dot_ydb__export__pb2.ExportToS3Request.SerializeToString,
                response_deserializer=protos_dot_ydb__export__pb2.ExportToS3Response.FromString,
                )


class ExportServiceServicer(object):
    """Missing associated documentation comment in .proto file."""

    def ExportToYt(self, request, context):
        """Exports data to YT.
        Method starts an asynchronous operation that can be cancelled while it is in progress.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ExportToS3(self, request, context):
        """Exports data to S3.
        Method starts an asynchronous operation that can be cancelled while it is in progress.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_ExportServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'ExportToYt': grpc.unary_unary_rpc_method_handler(
                    servicer.ExportToYt,
                    request_deserializer=protos_dot_ydb__export__pb2.ExportToYtRequest.FromString,
                    response_serializer=protos_dot_ydb__export__pb2.ExportToYtResponse.SerializeToString,
            ),
            'ExportToS3': grpc.unary_unary_rpc_method_handler(
                    servicer.ExportToS3,
                    request_deserializer=protos_dot_ydb__export__pb2.ExportToS3Request.FromString,
                    response_serializer=protos_dot_ydb__export__pb2.ExportToS3Response.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'Ydb.Export.V1.ExportService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class ExportService(object):
    """Missing associated documentation comment in .proto file."""

    @staticmethod
    def ExportToYt(request,
            target,
            options=(),
            channel_credentials=None,
            call_credentials=None,
            insecure=False,
            compression=None,
            wait_for_ready=None,
            timeout=None,
            metadata=None):
        return grpc.experimental.unary_unary(request, target, '/Ydb.Export.V1.ExportService/ExportToYt',
            protos_dot_ydb__export__pb2.ExportToYtRequest.SerializeToString,
            protos_dot_ydb__export__pb2.ExportToYtResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ExportToS3(request,
            target,
            options=(),
            channel_credentials=None,
            call_credentials=None,
            insecure=False,
            compression=None,
            wait_for_ready=None,
            timeout=None,
            metadata=None):
        return grpc.experimental.unary_unary(request, target, '/Ydb.Export.V1.ExportService/ExportToS3',
            protos_dot_ydb__export__pb2.ExportToS3Request.SerializeToString,
            protos_dot_ydb__export__pb2.ExportToS3Response.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
