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

from protos import ai_module_api_pb2 as protos_dot_ai__module__api__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.IsMatchInProgress = channel.unary_unary(
                '/protos.AIModuleAPI/IsMatchInProgress',
                request_serializer=protos_dot_ai__module__api__pb2.IsMatchInProgressRequest.SerializeToString,
                response_deserializer=protos_dot_ai__module__api__pb2.IsMatchInProgressReply.FromString,
                )
        self.GetGameDataFilePath = channel.unary_unary(
                '/protos.AIModuleAPI/GetGameDataFilePath',
                request_serializer=protos_dot_ai__module__api__pb2.GetGameDataFilePathRequest.SerializeToString,
                response_deserializer=protos_dot_ai__module__api__pb2.GetGameDataFilePathReply.FromString,
                )
        self.Unload = channel.unary_unary(
                '/protos.AIModuleAPI/Unload',
                request_serializer=protos_dot_ai__module__api__pb2.UnloadRequest.SerializeToString,
                response_deserializer=protos_dot_ai__module__api__pb2.UnloadReply.FromString,
                )


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

    def IsMatchInProgress(self, request, context):
        """*
        Check if a match is currently in progress.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def GetGameDataFilePath(self, request, context):
        """*
        Get the path to the game data (.dat) file that is being used by the game. Only available on AoC.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def Unload(self, request, context):
        """*
        Cancel any pending RPC calls, close the RPC server, remove detours and detach the AI Module from the game process.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_AIModuleAPIServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'IsMatchInProgress': grpc.unary_unary_rpc_method_handler(
                    servicer.IsMatchInProgress,
                    request_deserializer=protos_dot_ai__module__api__pb2.IsMatchInProgressRequest.FromString,
                    response_serializer=protos_dot_ai__module__api__pb2.IsMatchInProgressReply.SerializeToString,
            ),
            'GetGameDataFilePath': grpc.unary_unary_rpc_method_handler(
                    servicer.GetGameDataFilePath,
                    request_deserializer=protos_dot_ai__module__api__pb2.GetGameDataFilePathRequest.FromString,
                    response_serializer=protos_dot_ai__module__api__pb2.GetGameDataFilePathReply.SerializeToString,
            ),
            'Unload': grpc.unary_unary_rpc_method_handler(
                    servicer.Unload,
                    request_deserializer=protos_dot_ai__module__api__pb2.UnloadRequest.FromString,
                    response_serializer=protos_dot_ai__module__api__pb2.UnloadReply.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'protos.AIModuleAPI', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def IsMatchInProgress(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, '/protos.AIModuleAPI/IsMatchInProgress',
            protos_dot_ai__module__api__pb2.IsMatchInProgressRequest.SerializeToString,
            protos_dot_ai__module__api__pb2.IsMatchInProgressReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetGameDataFilePath(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, '/protos.AIModuleAPI/GetGameDataFilePath',
            protos_dot_ai__module__api__pb2.GetGameDataFilePathRequest.SerializeToString,
            protos_dot_ai__module__api__pb2.GetGameDataFilePathReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Unload(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, '/protos.AIModuleAPI/Unload',
            protos_dot_ai__module__api__pb2.UnloadRequest.SerializeToString,
            protos_dot_ai__module__api__pb2.UnloadReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
