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

from google.protobuf import empty_pb2 as google_dot_protobuf_dot_empty__pb2
import middleend_qos_volume_pb2 as middleend__qos__volume__pb2


class MiddleendQosVolumeServiceStub(object):
    """Middle End (Storage Services) APIs. For example, encryption, compression, raid, QoS, multipath, ...
    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.CreateQosVolume = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/CreateQosVolume',
                request_serializer=middleend__qos__volume__pb2.CreateQosVolumeRequest.SerializeToString,
                response_deserializer=middleend__qos__volume__pb2.QosVolume.FromString,
                )
        self.DeleteQosVolume = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/DeleteQosVolume',
                request_serializer=middleend__qos__volume__pb2.DeleteQosVolumeRequest.SerializeToString,
                response_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
                )
        self.UpdateQosVolume = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/UpdateQosVolume',
                request_serializer=middleend__qos__volume__pb2.UpdateQosVolumeRequest.SerializeToString,
                response_deserializer=middleend__qos__volume__pb2.QosVolume.FromString,
                )
        self.ListQosVolumes = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/ListQosVolumes',
                request_serializer=middleend__qos__volume__pb2.ListQosVolumesRequest.SerializeToString,
                response_deserializer=middleend__qos__volume__pb2.ListQosVolumesResponse.FromString,
                )
        self.GetQosVolume = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/GetQosVolume',
                request_serializer=middleend__qos__volume__pb2.GetQosVolumeRequest.SerializeToString,
                response_deserializer=middleend__qos__volume__pb2.QosVolume.FromString,
                )
        self.StatsQosVolume = channel.unary_unary(
                '/opi_api.storage.v1.MiddleendQosVolumeService/StatsQosVolume',
                request_serializer=middleend__qos__volume__pb2.StatsQosVolumeRequest.SerializeToString,
                response_deserializer=middleend__qos__volume__pb2.StatsQosVolumeResponse.FromString,
                )


class MiddleendQosVolumeServiceServicer(object):
    """Middle End (Storage Services) APIs. For example, encryption, compression, raid, QoS, multipath, ...
    """

    def CreateQosVolume(self, request, context):
        """Create an Qos Volume
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def DeleteQosVolume(self, request, context):
        """Delete an Qos Volume
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def UpdateQosVolume(self, request, context):
        """Update an Qos Volume
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListQosVolumes(self, request, context):
        """List Qos Volumes
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def GetQosVolume(self, request, context):
        """Get an Qos Volume
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def StatsQosVolume(self, request, context):
        """Get an Qos Volume statistics
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_MiddleendQosVolumeServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'CreateQosVolume': grpc.unary_unary_rpc_method_handler(
                    servicer.CreateQosVolume,
                    request_deserializer=middleend__qos__volume__pb2.CreateQosVolumeRequest.FromString,
                    response_serializer=middleend__qos__volume__pb2.QosVolume.SerializeToString,
            ),
            'DeleteQosVolume': grpc.unary_unary_rpc_method_handler(
                    servicer.DeleteQosVolume,
                    request_deserializer=middleend__qos__volume__pb2.DeleteQosVolumeRequest.FromString,
                    response_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
            ),
            'UpdateQosVolume': grpc.unary_unary_rpc_method_handler(
                    servicer.UpdateQosVolume,
                    request_deserializer=middleend__qos__volume__pb2.UpdateQosVolumeRequest.FromString,
                    response_serializer=middleend__qos__volume__pb2.QosVolume.SerializeToString,
            ),
            'ListQosVolumes': grpc.unary_unary_rpc_method_handler(
                    servicer.ListQosVolumes,
                    request_deserializer=middleend__qos__volume__pb2.ListQosVolumesRequest.FromString,
                    response_serializer=middleend__qos__volume__pb2.ListQosVolumesResponse.SerializeToString,
            ),
            'GetQosVolume': grpc.unary_unary_rpc_method_handler(
                    servicer.GetQosVolume,
                    request_deserializer=middleend__qos__volume__pb2.GetQosVolumeRequest.FromString,
                    response_serializer=middleend__qos__volume__pb2.QosVolume.SerializeToString,
            ),
            'StatsQosVolume': grpc.unary_unary_rpc_method_handler(
                    servicer.StatsQosVolume,
                    request_deserializer=middleend__qos__volume__pb2.StatsQosVolumeRequest.FromString,
                    response_serializer=middleend__qos__volume__pb2.StatsQosVolumeResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'opi_api.storage.v1.MiddleendQosVolumeService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class MiddleendQosVolumeService(object):
    """Middle End (Storage Services) APIs. For example, encryption, compression, raid, QoS, multipath, ...
    """

    @staticmethod
    def CreateQosVolume(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.storage.v1.MiddleendQosVolumeService/CreateQosVolume',
            middleend__qos__volume__pb2.CreateQosVolumeRequest.SerializeToString,
            middleend__qos__volume__pb2.QosVolume.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def DeleteQosVolume(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.storage.v1.MiddleendQosVolumeService/DeleteQosVolume',
            middleend__qos__volume__pb2.DeleteQosVolumeRequest.SerializeToString,
            google_dot_protobuf_dot_empty__pb2.Empty.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def UpdateQosVolume(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.storage.v1.MiddleendQosVolumeService/UpdateQosVolume',
            middleend__qos__volume__pb2.UpdateQosVolumeRequest.SerializeToString,
            middleend__qos__volume__pb2.QosVolume.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListQosVolumes(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.storage.v1.MiddleendQosVolumeService/ListQosVolumes',
            middleend__qos__volume__pb2.ListQosVolumesRequest.SerializeToString,
            middleend__qos__volume__pb2.ListQosVolumesResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetQosVolume(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.storage.v1.MiddleendQosVolumeService/GetQosVolume',
            middleend__qos__volume__pb2.GetQosVolumeRequest.SerializeToString,
            middleend__qos__volume__pb2.QosVolume.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def StatsQosVolume(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.storage.v1.MiddleendQosVolumeService/StatsQosVolume',
            middleend__qos__volume__pb2.StatsQosVolumeRequest.SerializeToString,
            middleend__qos__volume__pb2.StatsQosVolumeResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
