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

import redisgrpc.redislite_pb2 as redislite__pb2


class RedisLiteServerStub(object):
    """The greeting service definition.
    service Greeter {
    // Sends a greeting
    rpc SayHello (HelloRequest) returns (HelloReply) {}
    // Sends another greeting
    rpc SayHelloAgain (HelloRequest) returns (HelloReply) {}
    }

    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.InitConnection = channel.unary_unary(
                '/redislite.RedisLiteServer/InitConnection',
                request_serializer=redislite__pb2.InitRequest.SerializeToString,
                response_deserializer=redislite__pb2.InitReply.FromString,
                )
        self.Set = channel.unary_unary(
                '/redislite.RedisLiteServer/Set',
                request_serializer=redislite__pb2.SetRequest.SerializeToString,
                response_deserializer=redislite__pb2.SetReply.FromString,
                )
        self.Get = channel.unary_unary(
                '/redislite.RedisLiteServer/Get',
                request_serializer=redislite__pb2.GetRequest.SerializeToString,
                response_deserializer=redislite__pb2.GetReply.FromString,
                )


class RedisLiteServerServicer(object):
    """The greeting service definition.
    service Greeter {
    // Sends a greeting
    rpc SayHello (HelloRequest) returns (HelloReply) {}
    // Sends another greeting
    rpc SayHelloAgain (HelloRequest) returns (HelloReply) {}
    }

    """

    def InitConnection(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 Set(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 Get(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_RedisLiteServerServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'InitConnection': grpc.unary_unary_rpc_method_handler(
                    servicer.InitConnection,
                    request_deserializer=redislite__pb2.InitRequest.FromString,
                    response_serializer=redislite__pb2.InitReply.SerializeToString,
            ),
            'Set': grpc.unary_unary_rpc_method_handler(
                    servicer.Set,
                    request_deserializer=redislite__pb2.SetRequest.FromString,
                    response_serializer=redislite__pb2.SetReply.SerializeToString,
            ),
            'Get': grpc.unary_unary_rpc_method_handler(
                    servicer.Get,
                    request_deserializer=redislite__pb2.GetRequest.FromString,
                    response_serializer=redislite__pb2.GetReply.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'redislite.RedisLiteServer', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class RedisLiteServer(object):
    """The greeting service definition.
    service Greeter {
    // Sends a greeting
    rpc SayHello (HelloRequest) returns (HelloReply) {}
    // Sends another greeting
    rpc SayHelloAgain (HelloRequest) returns (HelloReply) {}
    }

    """

    @staticmethod
    def InitConnection(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, '/redislite.RedisLiteServer/InitConnection',
            redislite__pb2.InitRequest.SerializeToString,
            redislite__pb2.InitReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Set(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, '/redislite.RedisLiteServer/Set',
            redislite__pb2.SetRequest.SerializeToString,
            redislite__pb2.SetReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Get(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, '/redislite.RedisLiteServer/Get',
            redislite__pb2.GetRequest.SerializeToString,
            redislite__pb2.GetReply.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
