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

from google.protobuf import empty_pb2 as google_dot_protobuf_dot_empty__pb2
from tools.grpc_interfaces import tool_base_pb2 as tools_dot_grpc__interfaces_dot_tool__base__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.GetStatus = channel.unary_unary(
                '/com.science.foundry.tools.grpc_interfaces.ToolDriver/GetStatus',
                request_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
                response_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.StatusReply.FromString,
                )
        self.ExecuteCommand = channel.unary_unary(
                '/com.science.foundry.tools.grpc_interfaces.ToolDriver/ExecuteCommand',
                request_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.SerializeToString,
                response_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.ExecuteCommandReply.FromString,
                )
        self.EstimateDuration = channel.unary_unary(
                '/com.science.foundry.tools.grpc_interfaces.ToolDriver/EstimateDuration',
                request_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.SerializeToString,
                response_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.EstimateDurationReply.FromString,
                )
        self.Configure = channel.unary_unary(
                '/com.science.foundry.tools.grpc_interfaces.ToolDriver/Configure',
                request_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Config.SerializeToString,
                response_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.ConfigureReply.FromString,
                )


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

    def GetStatus(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 ExecuteCommand(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 EstimateDuration(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 Configure(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_ToolDriverServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'GetStatus': grpc.unary_unary_rpc_method_handler(
                    servicer.GetStatus,
                    request_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
                    response_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.StatusReply.SerializeToString,
            ),
            'ExecuteCommand': grpc.unary_unary_rpc_method_handler(
                    servicer.ExecuteCommand,
                    request_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.FromString,
                    response_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.ExecuteCommandReply.SerializeToString,
            ),
            'EstimateDuration': grpc.unary_unary_rpc_method_handler(
                    servicer.EstimateDuration,
                    request_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.FromString,
                    response_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.EstimateDurationReply.SerializeToString,
            ),
            'Configure': grpc.unary_unary_rpc_method_handler(
                    servicer.Configure,
                    request_deserializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.Config.FromString,
                    response_serializer=tools_dot_grpc__interfaces_dot_tool__base__pb2.ConfigureReply.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'com.science.foundry.tools.grpc_interfaces.ToolDriver', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def GetStatus(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, '/com.science.foundry.tools.grpc_interfaces.ToolDriver/GetStatus',
            google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
            tools_dot_grpc__interfaces_dot_tool__base__pb2.StatusReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ExecuteCommand(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, '/com.science.foundry.tools.grpc_interfaces.ToolDriver/ExecuteCommand',
            tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.SerializeToString,
            tools_dot_grpc__interfaces_dot_tool__base__pb2.ExecuteCommandReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def EstimateDuration(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, '/com.science.foundry.tools.grpc_interfaces.ToolDriver/EstimateDuration',
            tools_dot_grpc__interfaces_dot_tool__base__pb2.Command.SerializeToString,
            tools_dot_grpc__interfaces_dot_tool__base__pb2.EstimateDurationReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Configure(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, '/com.science.foundry.tools.grpc_interfaces.ToolDriver/Configure',
            tools_dot_grpc__interfaces_dot_tool__base__pb2.Config.SerializeToString,
            tools_dot_grpc__interfaces_dot_tool__base__pb2.ConfigureReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
