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

from a3m.api.transferservice.v1beta1 import (
    request_response_pb2 as a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2,
)


class TransferServiceStub:
    """Missing associated documentation comment in .proto file."""

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

        Args:
            channel: A grpc.Channel.
        """
        self.Submit = channel.unary_unary(
            "/a3m.api.transferservice.v1beta1.TransferService/Submit",
            request_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitRequest.SerializeToString,
            response_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitResponse.FromString,
        )
        self.Read = channel.unary_unary(
            "/a3m.api.transferservice.v1beta1.TransferService/Read",
            request_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadRequest.SerializeToString,
            response_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadResponse.FromString,
        )
        self.ListTasks = channel.unary_unary(
            "/a3m.api.transferservice.v1beta1.TransferService/ListTasks",
            request_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksRequest.SerializeToString,
            response_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksResponse.FromString,
        )
        self.Empty = channel.unary_unary(
            "/a3m.api.transferservice.v1beta1.TransferService/Empty",
            request_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyRequest.SerializeToString,
            response_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyResponse.FromString,
        )


class TransferServiceServicer:
    """Missing associated documentation comment in .proto file."""

    def Submit(self, request, context):
        """Submits a new transfer."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def Read(self, request, context):
        """Reads the status of a given transfer."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def ListTasks(self, request, context):
        """Lists all tasks in a given transfer."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def Empty(self, request, context):
        """Delete all contents from a3m's shared folders. Should only be called once processing is complete."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")


def add_TransferServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
        "Submit": grpc.unary_unary_rpc_method_handler(
            servicer.Submit,
            request_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitRequest.FromString,
            response_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitResponse.SerializeToString,
        ),
        "Read": grpc.unary_unary_rpc_method_handler(
            servicer.Read,
            request_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadRequest.FromString,
            response_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadResponse.SerializeToString,
        ),
        "ListTasks": grpc.unary_unary_rpc_method_handler(
            servicer.ListTasks,
            request_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksRequest.FromString,
            response_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksResponse.SerializeToString,
        ),
        "Empty": grpc.unary_unary_rpc_method_handler(
            servicer.Empty,
            request_deserializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyRequest.FromString,
            response_serializer=a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyResponse.SerializeToString,
        ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
        "a3m.api.transferservice.v1beta1.TransferService", rpc_method_handlers
    )
    server.add_generic_rpc_handlers((generic_handler,))


# This class is part of an EXPERIMENTAL API.
class TransferService:
    """Missing associated documentation comment in .proto file."""

    @staticmethod
    def Submit(
        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,
            "/a3m.api.transferservice.v1beta1.TransferService/Submit",
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitRequest.SerializeToString,
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.SubmitResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def Read(
        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,
            "/a3m.api.transferservice.v1beta1.TransferService/Read",
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadRequest.SerializeToString,
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ReadResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def ListTasks(
        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,
            "/a3m.api.transferservice.v1beta1.TransferService/ListTasks",
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksRequest.SerializeToString,
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.ListTasksResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )

    @staticmethod
    def Empty(
        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,
            "/a3m.api.transferservice.v1beta1.TransferService/Empty",
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyRequest.SerializeToString,
            a3m_dot_api_dot_transferservice_dot_v1beta1_dot_request__response__pb2.EmptyResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
        )
