from sqlalchemy import orm
from couchers.context import CouchersContext
"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import abc
import collections.abc
import grpc
import grpc.aio
import search_pb2
import typing


GRPC_GENERATED_VERSION: str
GRPC_VERSION: str

class SearchStub:
    def __init__(self, channel: grpc.Channel) -> None: ...
    Search: grpc.UnaryUnaryMultiCallable[search_pb2.SearchReq, search_pb2.SearchRes]
    """Search all content"""
    UserSearch: grpc.UnaryUnaryMultiCallable[search_pb2.UserSearchReq, search_pb2.UserSearchRes]
    """Search for users in particular with extra filters, e.g. hosts"""
    UserSearchV2: grpc.UnaryUnaryMultiCallable[search_pb2.UserSearchReq, search_pb2.UserSearchV2Res]
    """Search for users in particular with extra filters, e.g. hosts
    only returns used fields
    """
    EventSearch: grpc.UnaryUnaryMultiCallable[search_pb2.EventSearchReq, search_pb2.EventSearchRes]
    """Search for events in particular with extra filters"""

class SearchServicer(metaclass=abc.ABCMeta):
    @abc.abstractmethod
    def Search(
        self,
        request: search_pb2.SearchReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> search_pb2.SearchRes:
        """Search all content"""

    @abc.abstractmethod
    def UserSearch(
        self,
        request: search_pb2.UserSearchReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> search_pb2.UserSearchRes:
        """Search for users in particular with extra filters, e.g. hosts"""

    @abc.abstractmethod
    def UserSearchV2(
        self,
        request: search_pb2.UserSearchReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> search_pb2.UserSearchV2Res:
        """Search for users in particular with extra filters, e.g. hosts
        only returns used fields
        """

    @abc.abstractmethod
    def EventSearch(
        self,
        request: search_pb2.EventSearchReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> search_pb2.EventSearchRes:
        """Search for events in particular with extra filters"""

def add_SearchServicer_to_server(servicer: SearchServicer, server: grpc.Server) -> None: ...
