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

import grpc_auth_service.user_service_pb2 as user__service__pb2


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

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

        Args:
            channel: A grpc.Channel.
        """
        self.Create = channel.unary_unary(
                '/User/Create',
                request_serializer=user__service__pb2.CreateUserRequest.SerializeToString,
                response_deserializer=user__service__pb2.CreateUserResponse.FromString,
                )
        self.GetLoginHistory = channel.unary_unary(
                '/User/GetLoginHistory',
                request_serializer=user__service__pb2.GetUserLoginHistoryRequest.SerializeToString,
                response_deserializer=user__service__pb2.GetUserLoginHistoryResponse.FromString,
                )
        self.GetUserMe = channel.unary_unary(
                '/User/GetUserMe',
                request_serializer=user__service__pb2.GetUserMeRequest.SerializeToString,
                response_deserializer=user__service__pb2.GetUserMeResponse.FromString,
                )


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

    def Create(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 GetLoginHistory(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 GetUserMe(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_UserServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'Create': grpc.unary_unary_rpc_method_handler(
                    servicer.Create,
                    request_deserializer=user__service__pb2.CreateUserRequest.FromString,
                    response_serializer=user__service__pb2.CreateUserResponse.SerializeToString,
            ),
            'GetLoginHistory': grpc.unary_unary_rpc_method_handler(
                    servicer.GetLoginHistory,
                    request_deserializer=user__service__pb2.GetUserLoginHistoryRequest.FromString,
                    response_serializer=user__service__pb2.GetUserLoginHistoryResponse.SerializeToString,
            ),
            'GetUserMe': grpc.unary_unary_rpc_method_handler(
                    servicer.GetUserMe,
                    request_deserializer=user__service__pb2.GetUserMeRequest.FromString,
                    response_serializer=user__service__pb2.GetUserMeResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'User', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


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

    @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, '/User/Create',
            user__service__pb2.CreateUserRequest.SerializeToString,
            user__service__pb2.CreateUserResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetLoginHistory(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, '/User/GetLoginHistory',
            user__service__pb2.GetUserLoginHistoryRequest.SerializeToString,
            user__service__pb2.GetUserLoginHistoryResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetUserMe(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, '/User/GetUserMe',
            user__service__pb2.GetUserMeRequest.SerializeToString,
            user__service__pb2.GetUserMeResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
