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

from . import feature_requests_pb2 as feature__requests__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.GetFeatureRequests = channel.unary_unary(
                '/org.couchers.api.feature_requests.FeatureRequests/GetFeatureRequests',
                request_serializer=feature__requests__pb2.GetFeatureRequestsReq.SerializeToString,
                response_deserializer=feature__requests__pb2.GetFeatureRequestsRes.FromString,
                )
        self.CreateFeatureRequest = channel.unary_unary(
                '/org.couchers.api.feature_requests.FeatureRequests/CreateFeatureRequest',
                request_serializer=feature__requests__pb2.CreateFeatureRequestReq.SerializeToString,
                response_deserializer=feature__requests__pb2.FeatureRequest.FromString,
                )
        self.VoteOnFeatureRequest = channel.unary_unary(
                '/org.couchers.api.feature_requests.FeatureRequests/VoteOnFeatureRequest',
                request_serializer=feature__requests__pb2.VoteOnFeatureRequestReq.SerializeToString,
                response_deserializer=feature__requests__pb2.FeatureRequest.FromString,
                )


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

    def GetFeatureRequests(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 CreateFeatureRequest(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 VoteOnFeatureRequest(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_FeatureRequestsServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'GetFeatureRequests': grpc.unary_unary_rpc_method_handler(
                    servicer.GetFeatureRequests,
                    request_deserializer=feature__requests__pb2.GetFeatureRequestsReq.FromString,
                    response_serializer=feature__requests__pb2.GetFeatureRequestsRes.SerializeToString,
            ),
            'CreateFeatureRequest': grpc.unary_unary_rpc_method_handler(
                    servicer.CreateFeatureRequest,
                    request_deserializer=feature__requests__pb2.CreateFeatureRequestReq.FromString,
                    response_serializer=feature__requests__pb2.FeatureRequest.SerializeToString,
            ),
            'VoteOnFeatureRequest': grpc.unary_unary_rpc_method_handler(
                    servicer.VoteOnFeatureRequest,
                    request_deserializer=feature__requests__pb2.VoteOnFeatureRequestReq.FromString,
                    response_serializer=feature__requests__pb2.FeatureRequest.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'org.couchers.api.feature_requests.FeatureRequests', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def GetFeatureRequests(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, '/org.couchers.api.feature_requests.FeatureRequests/GetFeatureRequests',
            feature__requests__pb2.GetFeatureRequestsReq.SerializeToString,
            feature__requests__pb2.GetFeatureRequestsRes.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def CreateFeatureRequest(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, '/org.couchers.api.feature_requests.FeatureRequests/CreateFeatureRequest',
            feature__requests__pb2.CreateFeatureRequestReq.SerializeToString,
            feature__requests__pb2.FeatureRequest.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def VoteOnFeatureRequest(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, '/org.couchers.api.feature_requests.FeatureRequests/VoteOnFeatureRequest',
            feature__requests__pb2.VoteOnFeatureRequestReq.SerializeToString,
            feature__requests__pb2.FeatureRequest.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
