# 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 th2_grpc_hand import rhbatch_pb2 as th2__grpc__hand_dot_rhbatch__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.register = channel.unary_unary(
                '/RhBatch/register',
                request_serializer=th2__grpc__hand_dot_rhbatch__pb2.RhTargetServer.SerializeToString,
                response_deserializer=th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.FromString,
                )
        self.unregister = channel.unary_unary(
                '/RhBatch/unregister',
                request_serializer=th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.SerializeToString,
                response_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
                )
        self.executeRhActionsBatch = channel.unary_unary(
                '/RhBatch/executeRhActionsBatch',
                request_serializer=th2__grpc__hand_dot_rhbatch__pb2.RhActionsList.SerializeToString,
                response_deserializer=th2__grpc__hand_dot_rhbatch__pb2.RhBatchResponse.FromString,
                )


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

    def register(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 unregister(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 executeRhActionsBatch(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_RhBatchServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'register': grpc.unary_unary_rpc_method_handler(
                    servicer.register,
                    request_deserializer=th2__grpc__hand_dot_rhbatch__pb2.RhTargetServer.FromString,
                    response_serializer=th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.SerializeToString,
            ),
            'unregister': grpc.unary_unary_rpc_method_handler(
                    servicer.unregister,
                    request_deserializer=th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.FromString,
                    response_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
            ),
            'executeRhActionsBatch': grpc.unary_unary_rpc_method_handler(
                    servicer.executeRhActionsBatch,
                    request_deserializer=th2__grpc__hand_dot_rhbatch__pb2.RhActionsList.FromString,
                    response_serializer=th2__grpc__hand_dot_rhbatch__pb2.RhBatchResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'RhBatch', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def register(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, '/RhBatch/register',
            th2__grpc__hand_dot_rhbatch__pb2.RhTargetServer.SerializeToString,
            th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def unregister(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, '/RhBatch/unregister',
            th2__grpc__hand_dot_rhbatch__pb2.RhSessionID.SerializeToString,
            google_dot_protobuf_dot_empty__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def executeRhActionsBatch(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, '/RhBatch/executeRhActionsBatch',
            th2__grpc__hand_dot_rhbatch__pb2.RhActionsList.SerializeToString,
            th2__grpc__hand_dot_rhbatch__pb2.RhBatchResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
