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 google.protobuf.empty_pb2
import grpc
import grpc.aio
import references_pb2
import typing


GRPC_GENERATED_VERSION: str
GRPC_VERSION: str

class ReferencesStub:
    def __init__(self, channel: grpc.Channel) -> None: ...
    ListReferences: grpc.UnaryUnaryMultiCallable[references_pb2.ListReferencesReq, references_pb2.ListReferencesRes]
    """Returns a paginated list of references satisfying some filtering criterion"""
    WriteFriendReference: grpc.UnaryUnaryMultiCallable[references_pb2.WriteFriendReferenceReq, references_pb2.Reference]
    """Write a reference for your friend. Raises INVALID_ARGUMENT if you
    try to write for yourself, or NOT_FOUND if the user doesn't exist.
    Raises FAILED_PRECONDITION if you try to write a reference for someone you already wrote a friend reference for.
    """
    WriteHostRequestReference: grpc.UnaryUnaryMultiCallable[references_pb2.WriteHostRequestReferenceReq, references_pb2.Reference]
    """Write a reference for someone after having hosted/surfed with them. Raises NOT_FOUND if the request doesn't
    exist.
    """
    HostRequestIndicateDidntMeetup: grpc.UnaryUnaryMultiCallable[references_pb2.HostRequestIndicateDidntMeetupReq, google.protobuf.empty_pb2.Empty]
    """Indicate that the user didn't meet up"""
    AvailableWriteReferences: grpc.UnaryUnaryMultiCallable[references_pb2.AvailableWriteReferencesReq, references_pb2.AvailableWriteReferencesRes]
    """Return the reference types that is, at the moment, possible to write about a user."""
    ListPendingReferencesToWrite: grpc.UnaryUnaryMultiCallable[google.protobuf.empty_pb2.Empty, references_pb2.ListPendingReferencesToWriteRes]
    """Returns a list of references that you should write about others, e.g. after surfing or hosting"""
    GetHostRequestReferenceStatus: grpc.UnaryUnaryMultiCallable[references_pb2.GetHostRequestReferenceStatusReq, references_pb2.GetHostRequestReferenceStatusRes]
    """Returns status for whether the current user can write a host-request reference for the given request id"""

class ReferencesServicer(metaclass=abc.ABCMeta):
    @abc.abstractmethod
    def ListReferences(
        self,
        request: references_pb2.ListReferencesReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.ListReferencesRes:
        """Returns a paginated list of references satisfying some filtering criterion"""

    @abc.abstractmethod
    def WriteFriendReference(
        self,
        request: references_pb2.WriteFriendReferenceReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.Reference:
        """Write a reference for your friend. Raises INVALID_ARGUMENT if you
        try to write for yourself, or NOT_FOUND if the user doesn't exist.
        Raises FAILED_PRECONDITION if you try to write a reference for someone you already wrote a friend reference for.
        """

    @abc.abstractmethod
    def WriteHostRequestReference(
        self,
        request: references_pb2.WriteHostRequestReferenceReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.Reference:
        """Write a reference for someone after having hosted/surfed with them. Raises NOT_FOUND if the request doesn't
        exist.
        """

    @abc.abstractmethod
    def HostRequestIndicateDidntMeetup(
        self,
        request: references_pb2.HostRequestIndicateDidntMeetupReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> google.protobuf.empty_pb2.Empty:
        """Indicate that the user didn't meet up"""

    @abc.abstractmethod
    def AvailableWriteReferences(
        self,
        request: references_pb2.AvailableWriteReferencesReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.AvailableWriteReferencesRes:
        """Return the reference types that is, at the moment, possible to write about a user."""

    @abc.abstractmethod
    def ListPendingReferencesToWrite(
        self,
        request: google.protobuf.empty_pb2.Empty,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.ListPendingReferencesToWriteRes:
        """Returns a list of references that you should write about others, e.g. after surfing or hosting"""

    @abc.abstractmethod
    def GetHostRequestReferenceStatus(
        self,
        request: references_pb2.GetHostRequestReferenceStatusReq,
        context: CouchersContext,
        session: orm.Session,
    ) -> references_pb2.GetHostRequestReferenceStatusRes:
        """Returns status for whether the current user can write a host-request reference for the given request id"""

def add_ReferencesServicer_to_server(servicer: ReferencesServicer, server: grpc.Server) -> None: ...
