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

import ipsec_pb2 as ipsec__pb2


class IPsecServiceStub(object):
    """Service functions for IPSec Protocol 
    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.IPsecVersion = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecVersion',
                request_serializer=ipsec__pb2.IPsecVersionRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecVersionResponse.FromString,
                )
        self.IPsecStats = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecStats',
                request_serializer=ipsec__pb2.IPsecStatsRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecStatsResponse.FromString,
                )
        self.IPsecInitiate = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecInitiate',
                request_serializer=ipsec__pb2.IPsecInitiateRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecInitiateResponse.FromString,
                )
        self.IPsecTerminate = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecTerminate',
                request_serializer=ipsec__pb2.IPsecTerminateRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecTerminateResponse.FromString,
                )
        self.IPsecRekey = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecRekey',
                request_serializer=ipsec__pb2.IPsecRekeyRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecRekeyResponse.FromString,
                )
        self.IPsecListSas = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecListSas',
                request_serializer=ipsec__pb2.IPsecListSasRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecListSasResponse.FromString,
                )
        self.IPsecListConns = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecListConns',
                request_serializer=ipsec__pb2.IPsecListConnsRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecListConnsResponse.FromString,
                )
        self.IPsecListCerts = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecListCerts',
                request_serializer=ipsec__pb2.IPsecListCertsRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecListCertsResponse.FromString,
                )
        self.IPsecLoadConn = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecLoadConn',
                request_serializer=ipsec__pb2.IPsecLoadConnRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecLoadConnResponse.FromString,
                )
        self.IPsecUnloadConn = channel.unary_unary(
                '/opi_api.security.v1.IPsecService/IPsecUnloadConn',
                request_serializer=ipsec__pb2.IPsecUnloadConnRequest.SerializeToString,
                response_deserializer=ipsec__pb2.IPsecUnloadConnResponse.FromString,
                )


class IPsecServiceServicer(object):
    """Service functions for IPSec Protocol 
    """

    def IPsecVersion(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 IPsecStats(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 IPsecInitiate(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 IPsecTerminate(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 IPsecRekey(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 IPsecListSas(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 IPsecListConns(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 IPsecListCerts(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 IPsecLoadConn(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 IPsecUnloadConn(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_IPsecServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'IPsecVersion': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecVersion,
                    request_deserializer=ipsec__pb2.IPsecVersionRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecVersionResponse.SerializeToString,
            ),
            'IPsecStats': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecStats,
                    request_deserializer=ipsec__pb2.IPsecStatsRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecStatsResponse.SerializeToString,
            ),
            'IPsecInitiate': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecInitiate,
                    request_deserializer=ipsec__pb2.IPsecInitiateRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecInitiateResponse.SerializeToString,
            ),
            'IPsecTerminate': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecTerminate,
                    request_deserializer=ipsec__pb2.IPsecTerminateRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecTerminateResponse.SerializeToString,
            ),
            'IPsecRekey': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecRekey,
                    request_deserializer=ipsec__pb2.IPsecRekeyRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecRekeyResponse.SerializeToString,
            ),
            'IPsecListSas': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecListSas,
                    request_deserializer=ipsec__pb2.IPsecListSasRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecListSasResponse.SerializeToString,
            ),
            'IPsecListConns': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecListConns,
                    request_deserializer=ipsec__pb2.IPsecListConnsRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecListConnsResponse.SerializeToString,
            ),
            'IPsecListCerts': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecListCerts,
                    request_deserializer=ipsec__pb2.IPsecListCertsRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecListCertsResponse.SerializeToString,
            ),
            'IPsecLoadConn': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecLoadConn,
                    request_deserializer=ipsec__pb2.IPsecLoadConnRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecLoadConnResponse.SerializeToString,
            ),
            'IPsecUnloadConn': grpc.unary_unary_rpc_method_handler(
                    servicer.IPsecUnloadConn,
                    request_deserializer=ipsec__pb2.IPsecUnloadConnRequest.FromString,
                    response_serializer=ipsec__pb2.IPsecUnloadConnResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'opi_api.security.v1.IPsecService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class IPsecService(object):
    """Service functions for IPSec Protocol 
    """

    @staticmethod
    def IPsecVersion(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, '/opi_api.security.v1.IPsecService/IPsecVersion',
            ipsec__pb2.IPsecVersionRequest.SerializeToString,
            ipsec__pb2.IPsecVersionResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecStats(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, '/opi_api.security.v1.IPsecService/IPsecStats',
            ipsec__pb2.IPsecStatsRequest.SerializeToString,
            ipsec__pb2.IPsecStatsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecInitiate(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, '/opi_api.security.v1.IPsecService/IPsecInitiate',
            ipsec__pb2.IPsecInitiateRequest.SerializeToString,
            ipsec__pb2.IPsecInitiateResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecTerminate(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, '/opi_api.security.v1.IPsecService/IPsecTerminate',
            ipsec__pb2.IPsecTerminateRequest.SerializeToString,
            ipsec__pb2.IPsecTerminateResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecRekey(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, '/opi_api.security.v1.IPsecService/IPsecRekey',
            ipsec__pb2.IPsecRekeyRequest.SerializeToString,
            ipsec__pb2.IPsecRekeyResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecListSas(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, '/opi_api.security.v1.IPsecService/IPsecListSas',
            ipsec__pb2.IPsecListSasRequest.SerializeToString,
            ipsec__pb2.IPsecListSasResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecListConns(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, '/opi_api.security.v1.IPsecService/IPsecListConns',
            ipsec__pb2.IPsecListConnsRequest.SerializeToString,
            ipsec__pb2.IPsecListConnsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecListCerts(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, '/opi_api.security.v1.IPsecService/IPsecListCerts',
            ipsec__pb2.IPsecListCertsRequest.SerializeToString,
            ipsec__pb2.IPsecListCertsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecLoadConn(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, '/opi_api.security.v1.IPsecService/IPsecLoadConn',
            ipsec__pb2.IPsecLoadConnRequest.SerializeToString,
            ipsec__pb2.IPsecLoadConnResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def IPsecUnloadConn(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, '/opi_api.security.v1.IPsecService/IPsecUnloadConn',
            ipsec__pb2.IPsecUnloadConnRequest.SerializeToString,
            ipsec__pb2.IPsecUnloadConnResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
