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

from . import operations_pb2 as operations__pb2
from . import shared_pb2 as shared__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.StartScavenge = channel.unary_unary(
                '/event_store.client.operations.Operations/StartScavenge',
                request_serializer=operations__pb2.StartScavengeReq.SerializeToString,
                response_deserializer=operations__pb2.ScavengeResp.FromString,
                )
        self.StopScavenge = channel.unary_unary(
                '/event_store.client.operations.Operations/StopScavenge',
                request_serializer=operations__pb2.StopScavengeReq.SerializeToString,
                response_deserializer=operations__pb2.ScavengeResp.FromString,
                )
        self.Shutdown = channel.unary_unary(
                '/event_store.client.operations.Operations/Shutdown',
                request_serializer=shared__pb2.Empty.SerializeToString,
                response_deserializer=shared__pb2.Empty.FromString,
                )
        self.MergeIndexes = channel.unary_unary(
                '/event_store.client.operations.Operations/MergeIndexes',
                request_serializer=shared__pb2.Empty.SerializeToString,
                response_deserializer=shared__pb2.Empty.FromString,
                )
        self.ResignNode = channel.unary_unary(
                '/event_store.client.operations.Operations/ResignNode',
                request_serializer=shared__pb2.Empty.SerializeToString,
                response_deserializer=shared__pb2.Empty.FromString,
                )
        self.SetNodePriority = channel.unary_unary(
                '/event_store.client.operations.Operations/SetNodePriority',
                request_serializer=operations__pb2.SetNodePriorityReq.SerializeToString,
                response_deserializer=shared__pb2.Empty.FromString,
                )
        self.RestartPersistentSubscriptions = channel.unary_unary(
                '/event_store.client.operations.Operations/RestartPersistentSubscriptions',
                request_serializer=shared__pb2.Empty.SerializeToString,
                response_deserializer=shared__pb2.Empty.FromString,
                )


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

    def StartScavenge(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 StopScavenge(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 Shutdown(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 MergeIndexes(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 ResignNode(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 SetNodePriority(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 RestartPersistentSubscriptions(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_OperationsServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'StartScavenge': grpc.unary_unary_rpc_method_handler(
                    servicer.StartScavenge,
                    request_deserializer=operations__pb2.StartScavengeReq.FromString,
                    response_serializer=operations__pb2.ScavengeResp.SerializeToString,
            ),
            'StopScavenge': grpc.unary_unary_rpc_method_handler(
                    servicer.StopScavenge,
                    request_deserializer=operations__pb2.StopScavengeReq.FromString,
                    response_serializer=operations__pb2.ScavengeResp.SerializeToString,
            ),
            'Shutdown': grpc.unary_unary_rpc_method_handler(
                    servicer.Shutdown,
                    request_deserializer=shared__pb2.Empty.FromString,
                    response_serializer=shared__pb2.Empty.SerializeToString,
            ),
            'MergeIndexes': grpc.unary_unary_rpc_method_handler(
                    servicer.MergeIndexes,
                    request_deserializer=shared__pb2.Empty.FromString,
                    response_serializer=shared__pb2.Empty.SerializeToString,
            ),
            'ResignNode': grpc.unary_unary_rpc_method_handler(
                    servicer.ResignNode,
                    request_deserializer=shared__pb2.Empty.FromString,
                    response_serializer=shared__pb2.Empty.SerializeToString,
            ),
            'SetNodePriority': grpc.unary_unary_rpc_method_handler(
                    servicer.SetNodePriority,
                    request_deserializer=operations__pb2.SetNodePriorityReq.FromString,
                    response_serializer=shared__pb2.Empty.SerializeToString,
            ),
            'RestartPersistentSubscriptions': grpc.unary_unary_rpc_method_handler(
                    servicer.RestartPersistentSubscriptions,
                    request_deserializer=shared__pb2.Empty.FromString,
                    response_serializer=shared__pb2.Empty.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'event_store.client.operations.Operations', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def StartScavenge(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, '/event_store.client.operations.Operations/StartScavenge',
            operations__pb2.StartScavengeReq.SerializeToString,
            operations__pb2.ScavengeResp.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def StopScavenge(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, '/event_store.client.operations.Operations/StopScavenge',
            operations__pb2.StopScavengeReq.SerializeToString,
            operations__pb2.ScavengeResp.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Shutdown(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, '/event_store.client.operations.Operations/Shutdown',
            shared__pb2.Empty.SerializeToString,
            shared__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def MergeIndexes(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, '/event_store.client.operations.Operations/MergeIndexes',
            shared__pb2.Empty.SerializeToString,
            shared__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ResignNode(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, '/event_store.client.operations.Operations/ResignNode',
            shared__pb2.Empty.SerializeToString,
            shared__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def SetNodePriority(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, '/event_store.client.operations.Operations/SetNodePriority',
            operations__pb2.SetNodePriorityReq.SerializeToString,
            shared__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def RestartPersistentSubscriptions(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, '/event_store.client.operations.Operations/RestartPersistentSubscriptions',
            shared__pb2.Empty.SerializeToString,
            shared__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
