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

from terrascope_api.models import project_pb2 as project__pb2

GRPC_GENERATED_VERSION = '1.63.0'
GRPC_VERSION = grpc.__version__
EXPECTED_ERROR_RELEASE = '1.65.0'
SCHEDULED_RELEASE_DATE = 'June 25, 2024'
_version_not_supported = False

try:
    from grpc._utilities import first_version_is_lower
    _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
except ImportError:
    _version_not_supported = True

if _version_not_supported:
    warnings.warn(
        f'The grpc package installed is at version {GRPC_VERSION},'
        + f' but the generated code in project_pb2_grpc.py depends on'
        + f' grpcio>={GRPC_GENERATED_VERSION}.'
        + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
        + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
        + f' This warning will become an error in {EXPECTED_ERROR_RELEASE},'
        + f' scheduled for release on {SCHEDULED_RELEASE_DATE}.',
        RuntimeWarning
    )


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.list = channel.unary_unary(
                '/oi.papi.ProjectApi/list',
                request_serializer=project__pb2.ProjectListRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectListResponse.FromString,
                _registered_method=True)
        self.get = channel.unary_unary(
                '/oi.papi.ProjectApi/get',
                request_serializer=project__pb2.ProjectGetRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectGetResponse.FromString,
                _registered_method=True)
        self.create = channel.unary_unary(
                '/oi.papi.ProjectApi/create',
                request_serializer=project__pb2.ProjectCreateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectCreateResponse.FromString,
                _registered_method=True)
        self.update = channel.unary_unary(
                '/oi.papi.ProjectApi/update',
                request_serializer=project__pb2.ProjectUpdateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectUpdateResponse.FromString,
                _registered_method=True)
        self.delete = channel.unary_unary(
                '/oi.papi.ProjectApi/delete',
                request_serializer=project__pb2.ProjectDeleteRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectDeleteResponse.FromString,
                _registered_method=True)
        self.run = channel.unary_unary(
                '/oi.papi.ProjectApi/run',
                request_serializer=project__pb2.ProjectRunRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectRunResponse.FromString,
                _registered_method=True)
        self.create_project_result_filter_mapping = channel.unary_unary(
                '/oi.papi.ProjectApi/create_project_result_filter_mapping',
                request_serializer=project__pb2.ProjectResultFilterMappingCreateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectResultFilterMappingCreateResponse.FromString,
                _registered_method=True)
        self.delete_project_result_filter_mapping = channel.unary_unary(
                '/oi.papi.ProjectApi/delete_project_result_filter_mapping',
                request_serializer=project__pb2.ProjectResultFilterMappingDeleteRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectResultFilterMappingDeleteResponse.FromString,
                _registered_method=True)
        self.clone = channel.unary_unary(
                '/oi.papi.ProjectApi/clone',
                request_serializer=project__pb2.ProjectCloneRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectCloneResponse.FromString,
                _registered_method=True)
        self.list_group = channel.unary_unary(
                '/oi.papi.ProjectApi/list_group',
                request_serializer=project__pb2.ProjectGroupListRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectGroupListResponse.FromString,
                _registered_method=True)
        self.create_group = channel.unary_unary(
                '/oi.papi.ProjectApi/create_group',
                request_serializer=project__pb2.ProjectGroupCreateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectGroupCreateResponse.FromString,
                _registered_method=True)
        self.delete_group = channel.unary_unary(
                '/oi.papi.ProjectApi/delete_group',
                request_serializer=project__pb2.ProjectGroupDeleteRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectGroupDeleteResponse.FromString,
                _registered_method=True)
        self.update_group = channel.unary_unary(
                '/oi.papi.ProjectApi/update_group',
                request_serializer=project__pb2.ProjectGroupUpdateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectGroupUpdateResponse.FromString,
                _registered_method=True)
        self.get_collaborator = channel.unary_unary(
                '/oi.papi.ProjectApi/get_collaborator',
                request_serializer=project__pb2.ProjectCollaboratorGetRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectCollaboratorGetResponse.FromString,
                _registered_method=True)
        self.update_collaborator = channel.unary_unary(
                '/oi.papi.ProjectApi/update_collaborator',
                request_serializer=project__pb2.ProjectCollaboratorUpdateRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectCollaboratorUpdateResponse.FromString,
                _registered_method=True)
        self.delete_collaborator = channel.unary_unary(
                '/oi.papi.ProjectApi/delete_collaborator',
                request_serializer=project__pb2.ProjectCollaboratorDeleteRequest.SerializeToString,
                response_deserializer=project__pb2.ProjectCollaboratorDeleteResponse.FromString,
                _registered_method=True)


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

    def list(self, request, context):
        """
        List the Projects available to the user
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def get(self, request, context):
        """
        Get a specified Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def create(self, request, context):
        """
        Create a Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def update(self, request, context):
        """
        Update a Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def delete(self, request, context):
        """
        Delete a Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def run(self, request, context):
        """
        Run a Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def create_project_result_filter_mapping(self, request, context):
        """
        Create a project result filter mapping
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def delete_project_result_filter_mapping(self, request, context):
        """
        Delete a project result filter mapping
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def clone(self, request, context):
        """
        Clone a Project
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def list_group(self, request, context):
        """
        List Project Groups
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def create_group(self, request, context):
        """
        Create Project Groups
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def delete_group(self, request, context):
        """
        Delete Project Groups
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def update_group(self, request, context):
        """
        Update Project Groups
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def get_collaborator(self, request, context):
        """
        Get Project Collaborators
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def update_collaborator(self, request, context):
        """
        Create Project Collaborators
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def delete_collaborator(self, request, context):
        """
        Delete Project Collaborators
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_ProjectApiServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'list': grpc.unary_unary_rpc_method_handler(
                    servicer.list,
                    request_deserializer=project__pb2.ProjectListRequest.FromString,
                    response_serializer=project__pb2.ProjectListResponse.SerializeToString,
            ),
            'get': grpc.unary_unary_rpc_method_handler(
                    servicer.get,
                    request_deserializer=project__pb2.ProjectGetRequest.FromString,
                    response_serializer=project__pb2.ProjectGetResponse.SerializeToString,
            ),
            'create': grpc.unary_unary_rpc_method_handler(
                    servicer.create,
                    request_deserializer=project__pb2.ProjectCreateRequest.FromString,
                    response_serializer=project__pb2.ProjectCreateResponse.SerializeToString,
            ),
            'update': grpc.unary_unary_rpc_method_handler(
                    servicer.update,
                    request_deserializer=project__pb2.ProjectUpdateRequest.FromString,
                    response_serializer=project__pb2.ProjectUpdateResponse.SerializeToString,
            ),
            'delete': grpc.unary_unary_rpc_method_handler(
                    servicer.delete,
                    request_deserializer=project__pb2.ProjectDeleteRequest.FromString,
                    response_serializer=project__pb2.ProjectDeleteResponse.SerializeToString,
            ),
            'run': grpc.unary_unary_rpc_method_handler(
                    servicer.run,
                    request_deserializer=project__pb2.ProjectRunRequest.FromString,
                    response_serializer=project__pb2.ProjectRunResponse.SerializeToString,
            ),
            'create_project_result_filter_mapping': grpc.unary_unary_rpc_method_handler(
                    servicer.create_project_result_filter_mapping,
                    request_deserializer=project__pb2.ProjectResultFilterMappingCreateRequest.FromString,
                    response_serializer=project__pb2.ProjectResultFilterMappingCreateResponse.SerializeToString,
            ),
            'delete_project_result_filter_mapping': grpc.unary_unary_rpc_method_handler(
                    servicer.delete_project_result_filter_mapping,
                    request_deserializer=project__pb2.ProjectResultFilterMappingDeleteRequest.FromString,
                    response_serializer=project__pb2.ProjectResultFilterMappingDeleteResponse.SerializeToString,
            ),
            'clone': grpc.unary_unary_rpc_method_handler(
                    servicer.clone,
                    request_deserializer=project__pb2.ProjectCloneRequest.FromString,
                    response_serializer=project__pb2.ProjectCloneResponse.SerializeToString,
            ),
            'list_group': grpc.unary_unary_rpc_method_handler(
                    servicer.list_group,
                    request_deserializer=project__pb2.ProjectGroupListRequest.FromString,
                    response_serializer=project__pb2.ProjectGroupListResponse.SerializeToString,
            ),
            'create_group': grpc.unary_unary_rpc_method_handler(
                    servicer.create_group,
                    request_deserializer=project__pb2.ProjectGroupCreateRequest.FromString,
                    response_serializer=project__pb2.ProjectGroupCreateResponse.SerializeToString,
            ),
            'delete_group': grpc.unary_unary_rpc_method_handler(
                    servicer.delete_group,
                    request_deserializer=project__pb2.ProjectGroupDeleteRequest.FromString,
                    response_serializer=project__pb2.ProjectGroupDeleteResponse.SerializeToString,
            ),
            'update_group': grpc.unary_unary_rpc_method_handler(
                    servicer.update_group,
                    request_deserializer=project__pb2.ProjectGroupUpdateRequest.FromString,
                    response_serializer=project__pb2.ProjectGroupUpdateResponse.SerializeToString,
            ),
            'get_collaborator': grpc.unary_unary_rpc_method_handler(
                    servicer.get_collaborator,
                    request_deserializer=project__pb2.ProjectCollaboratorGetRequest.FromString,
                    response_serializer=project__pb2.ProjectCollaboratorGetResponse.SerializeToString,
            ),
            'update_collaborator': grpc.unary_unary_rpc_method_handler(
                    servicer.update_collaborator,
                    request_deserializer=project__pb2.ProjectCollaboratorUpdateRequest.FromString,
                    response_serializer=project__pb2.ProjectCollaboratorUpdateResponse.SerializeToString,
            ),
            'delete_collaborator': grpc.unary_unary_rpc_method_handler(
                    servicer.delete_collaborator,
                    request_deserializer=project__pb2.ProjectCollaboratorDeleteRequest.FromString,
                    response_serializer=project__pb2.ProjectCollaboratorDeleteResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'oi.papi.ProjectApi', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def list(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,
            '/oi.papi.ProjectApi/list',
            project__pb2.ProjectListRequest.SerializeToString,
            project__pb2.ProjectListResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def get(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,
            '/oi.papi.ProjectApi/get',
            project__pb2.ProjectGetRequest.SerializeToString,
            project__pb2.ProjectGetResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def create(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,
            '/oi.papi.ProjectApi/create',
            project__pb2.ProjectCreateRequest.SerializeToString,
            project__pb2.ProjectCreateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def update(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,
            '/oi.papi.ProjectApi/update',
            project__pb2.ProjectUpdateRequest.SerializeToString,
            project__pb2.ProjectUpdateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def delete(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,
            '/oi.papi.ProjectApi/delete',
            project__pb2.ProjectDeleteRequest.SerializeToString,
            project__pb2.ProjectDeleteResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def run(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,
            '/oi.papi.ProjectApi/run',
            project__pb2.ProjectRunRequest.SerializeToString,
            project__pb2.ProjectRunResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def create_project_result_filter_mapping(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,
            '/oi.papi.ProjectApi/create_project_result_filter_mapping',
            project__pb2.ProjectResultFilterMappingCreateRequest.SerializeToString,
            project__pb2.ProjectResultFilterMappingCreateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def delete_project_result_filter_mapping(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,
            '/oi.papi.ProjectApi/delete_project_result_filter_mapping',
            project__pb2.ProjectResultFilterMappingDeleteRequest.SerializeToString,
            project__pb2.ProjectResultFilterMappingDeleteResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def clone(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,
            '/oi.papi.ProjectApi/clone',
            project__pb2.ProjectCloneRequest.SerializeToString,
            project__pb2.ProjectCloneResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def list_group(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,
            '/oi.papi.ProjectApi/list_group',
            project__pb2.ProjectGroupListRequest.SerializeToString,
            project__pb2.ProjectGroupListResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def create_group(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,
            '/oi.papi.ProjectApi/create_group',
            project__pb2.ProjectGroupCreateRequest.SerializeToString,
            project__pb2.ProjectGroupCreateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def delete_group(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,
            '/oi.papi.ProjectApi/delete_group',
            project__pb2.ProjectGroupDeleteRequest.SerializeToString,
            project__pb2.ProjectGroupDeleteResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def update_group(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,
            '/oi.papi.ProjectApi/update_group',
            project__pb2.ProjectGroupUpdateRequest.SerializeToString,
            project__pb2.ProjectGroupUpdateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def get_collaborator(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,
            '/oi.papi.ProjectApi/get_collaborator',
            project__pb2.ProjectCollaboratorGetRequest.SerializeToString,
            project__pb2.ProjectCollaboratorGetResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def update_collaborator(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,
            '/oi.papi.ProjectApi/update_collaborator',
            project__pb2.ProjectCollaboratorUpdateRequest.SerializeToString,
            project__pb2.ProjectCollaboratorUpdateResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)

    @staticmethod
    def delete_collaborator(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,
            '/oi.papi.ProjectApi/delete_collaborator',
            project__pb2.ProjectCollaboratorDeleteRequest.SerializeToString,
            project__pb2.ProjectCollaboratorDeleteResponse.FromString,
            options,
            channel_credentials,
            insecure,
            call_credentials,
            compression,
            wait_for_ready,
            timeout,
            metadata,
            _registered_method=True)
