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

from . import pages_pb2 as pages__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.CreatePlace = channel.unary_unary(
                '/org.couchers.api.pages.Pages/CreatePlace',
                request_serializer=pages__pb2.CreatePlaceReq.SerializeToString,
                response_deserializer=pages__pb2.Page.FromString,
                )
        self.CreateGuide = channel.unary_unary(
                '/org.couchers.api.pages.Pages/CreateGuide',
                request_serializer=pages__pb2.CreateGuideReq.SerializeToString,
                response_deserializer=pages__pb2.Page.FromString,
                )
        self.GetPage = channel.unary_unary(
                '/org.couchers.api.pages.Pages/GetPage',
                request_serializer=pages__pb2.GetPageReq.SerializeToString,
                response_deserializer=pages__pb2.Page.FromString,
                )
        self.UpdatePage = channel.unary_unary(
                '/org.couchers.api.pages.Pages/UpdatePage',
                request_serializer=pages__pb2.UpdatePageReq.SerializeToString,
                response_deserializer=pages__pb2.Page.FromString,
                )
        self.TransferPage = channel.unary_unary(
                '/org.couchers.api.pages.Pages/TransferPage',
                request_serializer=pages__pb2.TransferPageReq.SerializeToString,
                response_deserializer=pages__pb2.Page.FromString,
                )
        self.ListUserPlaces = channel.unary_unary(
                '/org.couchers.api.pages.Pages/ListUserPlaces',
                request_serializer=pages__pb2.ListUserPlacesReq.SerializeToString,
                response_deserializer=pages__pb2.ListUserPlacesRes.FromString,
                )
        self.ListUserGuides = channel.unary_unary(
                '/org.couchers.api.pages.Pages/ListUserGuides',
                request_serializer=pages__pb2.ListUserGuidesReq.SerializeToString,
                response_deserializer=pages__pb2.ListUserGuidesRes.FromString,
                )


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

    def CreatePlace(self, request, context):
        """Creates a place
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def CreateGuide(self, request, context):
        """Creates a guide
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def GetPage(self, request, context):
        """Gets a page
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def UpdatePage(self, request, context):
        """Edit a page
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def TransferPage(self, request, context):
        """Transfer a page you own to either a group or a community
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListUserPlaces(self, request, context):
        """Gets a list of places pages a user owns
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListUserGuides(self, request, context):
        """Gets a list of guide pages a user owns
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_PagesServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'CreatePlace': grpc.unary_unary_rpc_method_handler(
                    servicer.CreatePlace,
                    request_deserializer=pages__pb2.CreatePlaceReq.FromString,
                    response_serializer=pages__pb2.Page.SerializeToString,
            ),
            'CreateGuide': grpc.unary_unary_rpc_method_handler(
                    servicer.CreateGuide,
                    request_deserializer=pages__pb2.CreateGuideReq.FromString,
                    response_serializer=pages__pb2.Page.SerializeToString,
            ),
            'GetPage': grpc.unary_unary_rpc_method_handler(
                    servicer.GetPage,
                    request_deserializer=pages__pb2.GetPageReq.FromString,
                    response_serializer=pages__pb2.Page.SerializeToString,
            ),
            'UpdatePage': grpc.unary_unary_rpc_method_handler(
                    servicer.UpdatePage,
                    request_deserializer=pages__pb2.UpdatePageReq.FromString,
                    response_serializer=pages__pb2.Page.SerializeToString,
            ),
            'TransferPage': grpc.unary_unary_rpc_method_handler(
                    servicer.TransferPage,
                    request_deserializer=pages__pb2.TransferPageReq.FromString,
                    response_serializer=pages__pb2.Page.SerializeToString,
            ),
            'ListUserPlaces': grpc.unary_unary_rpc_method_handler(
                    servicer.ListUserPlaces,
                    request_deserializer=pages__pb2.ListUserPlacesReq.FromString,
                    response_serializer=pages__pb2.ListUserPlacesRes.SerializeToString,
            ),
            'ListUserGuides': grpc.unary_unary_rpc_method_handler(
                    servicer.ListUserGuides,
                    request_deserializer=pages__pb2.ListUserGuidesReq.FromString,
                    response_serializer=pages__pb2.ListUserGuidesRes.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'org.couchers.api.pages.Pages', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @staticmethod
    def CreatePlace(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.pages.Pages/CreatePlace',
            pages__pb2.CreatePlaceReq.SerializeToString,
            pages__pb2.Page.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def CreateGuide(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.pages.Pages/CreateGuide',
            pages__pb2.CreateGuideReq.SerializeToString,
            pages__pb2.Page.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetPage(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.pages.Pages/GetPage',
            pages__pb2.GetPageReq.SerializeToString,
            pages__pb2.Page.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def UpdatePage(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.pages.Pages/UpdatePage',
            pages__pb2.UpdatePageReq.SerializeToString,
            pages__pb2.Page.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def TransferPage(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.pages.Pages/TransferPage',
            pages__pb2.TransferPageReq.SerializeToString,
            pages__pb2.Page.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListUserPlaces(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.pages.Pages/ListUserPlaces',
            pages__pb2.ListUserPlacesReq.SerializeToString,
            pages__pb2.ListUserPlacesRes.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListUserGuides(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.pages.Pages/ListUserGuides',
            pages__pb2.ListUserGuidesReq.SerializeToString,
            pages__pb2.ListUserGuidesRes.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
