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

import grpc
from process import process_pb2 as process_dot_process__pb2

GRPC_GENERATED_VERSION = "1.76.0"
GRPC_VERSION = grpc.__version__
_version_not_supported = False

try:
    from grpc._utilities import first_version_is_lower

    _version_not_supported = first_version_is_lower(
        GRPC_VERSION, GRPC_GENERATED_VERSION
    )
except ImportError:
    _version_not_supported = True

if _version_not_supported:
    raise RuntimeError(
        f"The grpc package installed is at version {GRPC_VERSION},"
        + " but the generated code in process/process_pb2_grpc.py depends on"
        + f" grpcio>={GRPC_GENERATED_VERSION}."
        + f" Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}"
        + f" or downgrade your generated code using grpcio-tools<={GRPC_VERSION}."
    )


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.List = channel.unary_unary(
            "/process.Process/List",
            request_serializer=process_dot_process__pb2.ListRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.ListResponse.FromString,
            _registered_method=True,
        )
        self.Connect = channel.unary_stream(
            "/process.Process/Connect",
            request_serializer=process_dot_process__pb2.ConnectRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.ConnectResponse.FromString,
            _registered_method=True,
        )
        self.Start = channel.unary_stream(
            "/process.Process/Start",
            request_serializer=process_dot_process__pb2.StartRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.StartResponse.FromString,
            _registered_method=True,
        )
        self.Update = channel.unary_unary(
            "/process.Process/Update",
            request_serializer=process_dot_process__pb2.UpdateRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.UpdateResponse.FromString,
            _registered_method=True,
        )
        self.StreamInput = channel.stream_unary(
            "/process.Process/StreamInput",
            request_serializer=process_dot_process__pb2.StreamInputRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.StreamInputResponse.FromString,
            _registered_method=True,
        )
        self.SendInput = channel.unary_unary(
            "/process.Process/SendInput",
            request_serializer=process_dot_process__pb2.SendInputRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.SendInputResponse.FromString,
            _registered_method=True,
        )
        self.SendSignal = channel.unary_unary(
            "/process.Process/SendSignal",
            request_serializer=process_dot_process__pb2.SendSignalRequest.SerializeToString,
            response_deserializer=process_dot_process__pb2.SendSignalResponse.FromString,
            _registered_method=True,
        )


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

    def List(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def Connect(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def Start(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def Update(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def StreamInput(self, request_iterator, context):
        """Client input stream ensures ordering of messages"""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def SendInput(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")

    def SendSignal(self, request, context):
        """Missing associated documentation comment in .proto file."""
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details("Method not implemented!")
        raise NotImplementedError("Method not implemented!")


def add_ProcessServicer_to_server(servicer, server):
    rpc_method_handlers = {
        "List": grpc.unary_unary_rpc_method_handler(
            servicer.List,
            request_deserializer=process_dot_process__pb2.ListRequest.FromString,
            response_serializer=process_dot_process__pb2.ListResponse.SerializeToString,
        ),
        "Connect": grpc.unary_stream_rpc_method_handler(
            servicer.Connect,
            request_deserializer=process_dot_process__pb2.ConnectRequest.FromString,
            response_serializer=process_dot_process__pb2.ConnectResponse.SerializeToString,
        ),
        "Start": grpc.unary_stream_rpc_method_handler(
            servicer.Start,
            request_deserializer=process_dot_process__pb2.StartRequest.FromString,
            response_serializer=process_dot_process__pb2.StartResponse.SerializeToString,
        ),
        "Update": grpc.unary_unary_rpc_method_handler(
            servicer.Update,
            request_deserializer=process_dot_process__pb2.UpdateRequest.FromString,
            response_serializer=process_dot_process__pb2.UpdateResponse.SerializeToString,
        ),
        "StreamInput": grpc.stream_unary_rpc_method_handler(
            servicer.StreamInput,
            request_deserializer=process_dot_process__pb2.StreamInputRequest.FromString,
            response_serializer=process_dot_process__pb2.StreamInputResponse.SerializeToString,
        ),
        "SendInput": grpc.unary_unary_rpc_method_handler(
            servicer.SendInput,
            request_deserializer=process_dot_process__pb2.SendInputRequest.FromString,
            response_serializer=process_dot_process__pb2.SendInputResponse.SerializeToString,
        ),
        "SendSignal": grpc.unary_unary_rpc_method_handler(
            servicer.SendSignal,
            request_deserializer=process_dot_process__pb2.SendSignalRequest.FromString,
            response_serializer=process_dot_process__pb2.SendSignalResponse.SerializeToString,
        ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
        "process.Process", rpc_method_handlers
    )
    server.add_generic_rpc_handlers((generic_handler,))
    server.add_registered_method_handlers("process.Process", rpc_method_handlers)


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

    @staticmethod
    def List(
        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,
            "/process.Process/List",
            process_dot_process__pb2.ListRequest.SerializeToString,
            process_dot_process__pb2.ListResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def Connect(
        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_stream(
            request,
            target,
            "/process.Process/Connect",
            process_dot_process__pb2.ConnectRequest.SerializeToString,
            process_dot_process__pb2.ConnectResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def Start(
        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_stream(
            request,
            target,
            "/process.Process/Start",
            process_dot_process__pb2.StartRequest.SerializeToString,
            process_dot_process__pb2.StartResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def Update(
        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,
            "/process.Process/Update",
            process_dot_process__pb2.UpdateRequest.SerializeToString,
            process_dot_process__pb2.UpdateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def StreamInput(
        request_iterator,
        target,
        options=(),
        channel_credentials=None,
        call_credentials=None,
        insecure=False,
        compression=None,
        wait_for_ready=None,
        timeout=None,
        metadata=None,
    ):
        return grpc.experimental.stream_unary(
            request_iterator,
            target,
            "/process.Process/StreamInput",
            process_dot_process__pb2.StreamInputRequest.SerializeToString,
            process_dot_process__pb2.StreamInputResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def SendInput(
        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,
            "/process.Process/SendInput",
            process_dot_process__pb2.SendInputRequest.SerializeToString,
            process_dot_process__pb2.SendInputResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )

    @staticmethod
    def SendSignal(
        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,
            "/process.Process/SendSignal",
            process_dot_process__pb2.SendSignalRequest.SerializeToString,
            process_dot_process__pb2.SendSignalResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True,
        )
