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

from queryservice_client.protobuf.common import verify_pb2 as common_dot_verify__pb2
from google.protobuf import empty_pb2 as google_dot_protobuf_dot_empty__pb2
from queryservice_client.protobuf.rdbms import mde_pb2 as rdbms_dot_mde__pb2
from queryservice_client.protobuf.rdbms import profiling_pb2 as rdbms_dot_profiling__pb2
from queryservice_client.protobuf.rdbms import qle_pb2 as rdbms_dot_qle__pb2
from queryservice_client.protobuf.rdbms import query_pb2 as rdbms_dot_query__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.ConfigurationVerification = channel.unary_unary(
                '/rdbms.Rdbms/ConfigurationVerification',
                request_serializer=common_dot_verify__pb2.Request.SerializeToString,
                response_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
                )
        self.FilterExtraction = channel.unary_stream(
                '/rdbms.Rdbms/FilterExtraction',
                request_serializer=rdbms_dot_mde__pb2.FilterExtractionRequest.SerializeToString,
                response_deserializer=rdbms_dot_mde__pb2.FilterExtractionResponse.FromString,
                )
        self.MetadataExtraction = channel.unary_stream(
                '/rdbms.Rdbms/MetadataExtraction',
                request_serializer=rdbms_dot_mde__pb2.MetadataExtractionRequest.SerializeToString,
                response_deserializer=rdbms_dot_mde__pb2.MetadataExtractionResponse.FromString,
                )
        self.TableExtraction = channel.unary_stream(
                '/rdbms.Rdbms/TableExtraction',
                request_serializer=rdbms_dot_mde__pb2.TableExtractionRequest.SerializeToString,
                response_deserializer=rdbms_dot_mde__pb2.TableExtractionResponse.FromString,
                )
        self.QuerylogExtraction = channel.unary_stream(
                '/rdbms.Rdbms/QuerylogExtraction',
                request_serializer=rdbms_dot_qle__pb2.Request.SerializeToString,
                response_deserializer=rdbms_dot_qle__pb2.Response.FromString,
                )
        self.TableProfiling = channel.unary_stream(
                '/rdbms.Rdbms/TableProfiling',
                request_serializer=rdbms_dot_profiling__pb2.TableProfilingRequest.SerializeToString,
                response_deserializer=rdbms_dot_profiling__pb2.TableProfilingResponse.FromString,
                )
        self.ColumnProfiling = channel.unary_stream(
                '/rdbms.Rdbms/ColumnProfiling',
                request_serializer=rdbms_dot_profiling__pb2.ColumnProfilingRequest.SerializeToString,
                response_deserializer=rdbms_dot_profiling__pb2.ColumnProfilingResponse.FromString,
                )
        self.CustomTableProfiling = channel.unary_stream(
                '/rdbms.Rdbms/CustomTableProfiling',
                request_serializer=rdbms_dot_profiling__pb2.CustomTableProfilingRequest.SerializeToString,
                response_deserializer=rdbms_dot_profiling__pb2.CustomTableProfilingResponse.FromString,
                )
        self.CustomColumnProfiling = channel.unary_stream(
                '/rdbms.Rdbms/CustomColumnProfiling',
                request_serializer=rdbms_dot_profiling__pb2.CustomColumnProfilingRequest.SerializeToString,
                response_deserializer=rdbms_dot_profiling__pb2.ColumnProfilingResponse.FromString,
                )
        self.StartSession = channel.unary_unary(
                '/rdbms.Rdbms/StartSession',
                request_serializer=rdbms_dot_query__pb2.StartSessionRequest.SerializeToString,
                response_deserializer=rdbms_dot_query__pb2.StartSessionResponse.FromString,
                )
        self.EndSession = channel.unary_unary(
                '/rdbms.Rdbms/EndSession',
                request_serializer=rdbms_dot_query__pb2.EndSessionRequest.SerializeToString,
                response_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
                )
        self.Query = channel.unary_stream(
                '/rdbms.Rdbms/Query',
                request_serializer=rdbms_dot_query__pb2.QueryRequest.SerializeToString,
                response_deserializer=rdbms_dot_query__pb2.QueryResponse.FromString,
                )
        self.CancelQuery = channel.unary_unary(
                '/rdbms.Rdbms/CancelQuery',
                request_serializer=rdbms_dot_query__pb2.CancelQueryRequest.SerializeToString,
                response_deserializer=rdbms_dot_query__pb2.CancelQueryResponse.FromString,
                )


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

    def ConfigurationVerification(self, request, context):
        """Verify that the connector has been configured correctly.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def FilterExtraction(self, request, context):
        """Retrieve all objects that can be used to filter metadata extraction.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def MetadataExtraction(self, request, context):
        """Run full or selective extraction extraction
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def TableExtraction(self, request, context):
        """Retrieve metadata for a single Table.
        This method is called as a downstream step to a user running a DDL statement on Compose.
        If the connector does not support Compose, then this method does not need to be implemented.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def QuerylogExtraction(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 TableProfiling(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 ColumnProfiling(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 CustomTableProfiling(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 CustomColumnProfiling(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 StartSession(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 EndSession(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 Query(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 CancelQuery(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_RdbmsServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'ConfigurationVerification': grpc.unary_unary_rpc_method_handler(
                    servicer.ConfigurationVerification,
                    request_deserializer=common_dot_verify__pb2.Request.FromString,
                    response_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
            ),
            'FilterExtraction': grpc.unary_stream_rpc_method_handler(
                    servicer.FilterExtraction,
                    request_deserializer=rdbms_dot_mde__pb2.FilterExtractionRequest.FromString,
                    response_serializer=rdbms_dot_mde__pb2.FilterExtractionResponse.SerializeToString,
            ),
            'MetadataExtraction': grpc.unary_stream_rpc_method_handler(
                    servicer.MetadataExtraction,
                    request_deserializer=rdbms_dot_mde__pb2.MetadataExtractionRequest.FromString,
                    response_serializer=rdbms_dot_mde__pb2.MetadataExtractionResponse.SerializeToString,
            ),
            'TableExtraction': grpc.unary_stream_rpc_method_handler(
                    servicer.TableExtraction,
                    request_deserializer=rdbms_dot_mde__pb2.TableExtractionRequest.FromString,
                    response_serializer=rdbms_dot_mde__pb2.TableExtractionResponse.SerializeToString,
            ),
            'QuerylogExtraction': grpc.unary_stream_rpc_method_handler(
                    servicer.QuerylogExtraction,
                    request_deserializer=rdbms_dot_qle__pb2.Request.FromString,
                    response_serializer=rdbms_dot_qle__pb2.Response.SerializeToString,
            ),
            'TableProfiling': grpc.unary_stream_rpc_method_handler(
                    servicer.TableProfiling,
                    request_deserializer=rdbms_dot_profiling__pb2.TableProfilingRequest.FromString,
                    response_serializer=rdbms_dot_profiling__pb2.TableProfilingResponse.SerializeToString,
            ),
            'ColumnProfiling': grpc.unary_stream_rpc_method_handler(
                    servicer.ColumnProfiling,
                    request_deserializer=rdbms_dot_profiling__pb2.ColumnProfilingRequest.FromString,
                    response_serializer=rdbms_dot_profiling__pb2.ColumnProfilingResponse.SerializeToString,
            ),
            'CustomTableProfiling': grpc.unary_stream_rpc_method_handler(
                    servicer.CustomTableProfiling,
                    request_deserializer=rdbms_dot_profiling__pb2.CustomTableProfilingRequest.FromString,
                    response_serializer=rdbms_dot_profiling__pb2.CustomTableProfilingResponse.SerializeToString,
            ),
            'CustomColumnProfiling': grpc.unary_stream_rpc_method_handler(
                    servicer.CustomColumnProfiling,
                    request_deserializer=rdbms_dot_profiling__pb2.CustomColumnProfilingRequest.FromString,
                    response_serializer=rdbms_dot_profiling__pb2.ColumnProfilingResponse.SerializeToString,
            ),
            'StartSession': grpc.unary_unary_rpc_method_handler(
                    servicer.StartSession,
                    request_deserializer=rdbms_dot_query__pb2.StartSessionRequest.FromString,
                    response_serializer=rdbms_dot_query__pb2.StartSessionResponse.SerializeToString,
            ),
            'EndSession': grpc.unary_unary_rpc_method_handler(
                    servicer.EndSession,
                    request_deserializer=rdbms_dot_query__pb2.EndSessionRequest.FromString,
                    response_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
            ),
            'Query': grpc.unary_stream_rpc_method_handler(
                    servicer.Query,
                    request_deserializer=rdbms_dot_query__pb2.QueryRequest.FromString,
                    response_serializer=rdbms_dot_query__pb2.QueryResponse.SerializeToString,
            ),
            'CancelQuery': grpc.unary_unary_rpc_method_handler(
                    servicer.CancelQuery,
                    request_deserializer=rdbms_dot_query__pb2.CancelQueryRequest.FromString,
                    response_serializer=rdbms_dot_query__pb2.CancelQueryResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'rdbms.Rdbms', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def ConfigurationVerification(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, '/rdbms.Rdbms/ConfigurationVerification',
            common_dot_verify__pb2.Request.SerializeToString,
            google_dot_protobuf_dot_empty__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def FilterExtraction(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, '/rdbms.Rdbms/FilterExtraction',
            rdbms_dot_mde__pb2.FilterExtractionRequest.SerializeToString,
            rdbms_dot_mde__pb2.FilterExtractionResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def MetadataExtraction(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, '/rdbms.Rdbms/MetadataExtraction',
            rdbms_dot_mde__pb2.MetadataExtractionRequest.SerializeToString,
            rdbms_dot_mde__pb2.MetadataExtractionResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def TableExtraction(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, '/rdbms.Rdbms/TableExtraction',
            rdbms_dot_mde__pb2.TableExtractionRequest.SerializeToString,
            rdbms_dot_mde__pb2.TableExtractionResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def QuerylogExtraction(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, '/rdbms.Rdbms/QuerylogExtraction',
            rdbms_dot_qle__pb2.Request.SerializeToString,
            rdbms_dot_qle__pb2.Response.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def TableProfiling(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, '/rdbms.Rdbms/TableProfiling',
            rdbms_dot_profiling__pb2.TableProfilingRequest.SerializeToString,
            rdbms_dot_profiling__pb2.TableProfilingResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ColumnProfiling(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, '/rdbms.Rdbms/ColumnProfiling',
            rdbms_dot_profiling__pb2.ColumnProfilingRequest.SerializeToString,
            rdbms_dot_profiling__pb2.ColumnProfilingResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def CustomTableProfiling(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, '/rdbms.Rdbms/CustomTableProfiling',
            rdbms_dot_profiling__pb2.CustomTableProfilingRequest.SerializeToString,
            rdbms_dot_profiling__pb2.CustomTableProfilingResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def CustomColumnProfiling(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, '/rdbms.Rdbms/CustomColumnProfiling',
            rdbms_dot_profiling__pb2.CustomColumnProfilingRequest.SerializeToString,
            rdbms_dot_profiling__pb2.ColumnProfilingResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def StartSession(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, '/rdbms.Rdbms/StartSession',
            rdbms_dot_query__pb2.StartSessionRequest.SerializeToString,
            rdbms_dot_query__pb2.StartSessionResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def EndSession(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, '/rdbms.Rdbms/EndSession',
            rdbms_dot_query__pb2.EndSessionRequest.SerializeToString,
            google_dot_protobuf_dot_empty__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Query(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, '/rdbms.Rdbms/Query',
            rdbms_dot_query__pb2.QueryRequest.SerializeToString,
            rdbms_dot_query__pb2.QueryResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def CancelQuery(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, '/rdbms.Rdbms/CancelQuery',
            rdbms_dot_query__pb2.CancelQueryRequest.SerializeToString,
            rdbms_dot_query__pb2.CancelQueryResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
