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

from h2o_notebook.gen.ai.h2o.notebook.v1 import kernel_image_service_pb2 as ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2


class KernelImageServiceStub(object):
    """KernelImageService manages KernelImage resources.
    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.CreateKernelImage = channel.unary_unary(
                '/ai.h2o.notebook.v1.KernelImageService/CreateKernelImage',
                request_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageRequest.SerializeToString,
                response_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageResponse.FromString,
                )
        self.GetKernelImage = channel.unary_unary(
                '/ai.h2o.notebook.v1.KernelImageService/GetKernelImage',
                request_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageRequest.SerializeToString,
                response_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageResponse.FromString,
                )
        self.ListKernelImages = channel.unary_unary(
                '/ai.h2o.notebook.v1.KernelImageService/ListKernelImages',
                request_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesRequest.SerializeToString,
                response_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesResponse.FromString,
                )
        self.UpdateKernelImage = channel.unary_unary(
                '/ai.h2o.notebook.v1.KernelImageService/UpdateKernelImage',
                request_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageRequest.SerializeToString,
                response_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageResponse.FromString,
                )
        self.DeleteKernelImage = channel.unary_unary(
                '/ai.h2o.notebook.v1.KernelImageService/DeleteKernelImage',
                request_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageRequest.SerializeToString,
                response_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageResponse.FromString,
                )


class KernelImageServiceServicer(object):
    """KernelImageService manages KernelImage resources.
    """

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

    def GetKernelImage(self, request, context):
        """Returns a specific KernelImage.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def ListKernelImages(self, request, context):
        """Returns a collection of KernelImages.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def UpdateKernelImage(self, request, context):
        """Updates a KernelImage.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def DeleteKernelImage(self, request, context):
        """Deletes a KernelImage.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_KernelImageServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'CreateKernelImage': grpc.unary_unary_rpc_method_handler(
                    servicer.CreateKernelImage,
                    request_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageRequest.FromString,
                    response_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageResponse.SerializeToString,
            ),
            'GetKernelImage': grpc.unary_unary_rpc_method_handler(
                    servicer.GetKernelImage,
                    request_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageRequest.FromString,
                    response_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageResponse.SerializeToString,
            ),
            'ListKernelImages': grpc.unary_unary_rpc_method_handler(
                    servicer.ListKernelImages,
                    request_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesRequest.FromString,
                    response_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesResponse.SerializeToString,
            ),
            'UpdateKernelImage': grpc.unary_unary_rpc_method_handler(
                    servicer.UpdateKernelImage,
                    request_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageRequest.FromString,
                    response_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageResponse.SerializeToString,
            ),
            'DeleteKernelImage': grpc.unary_unary_rpc_method_handler(
                    servicer.DeleteKernelImage,
                    request_deserializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageRequest.FromString,
                    response_serializer=ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageResponse.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'ai.h2o.notebook.v1.KernelImageService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class KernelImageService(object):
    """KernelImageService manages KernelImage resources.
    """

    @staticmethod
    def CreateKernelImage(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, '/ai.h2o.notebook.v1.KernelImageService/CreateKernelImage',
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageRequest.SerializeToString,
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.CreateKernelImageResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetKernelImage(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, '/ai.h2o.notebook.v1.KernelImageService/GetKernelImage',
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageRequest.SerializeToString,
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.GetKernelImageResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def ListKernelImages(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, '/ai.h2o.notebook.v1.KernelImageService/ListKernelImages',
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesRequest.SerializeToString,
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.ListKernelImagesResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def UpdateKernelImage(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, '/ai.h2o.notebook.v1.KernelImageService/UpdateKernelImage',
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageRequest.SerializeToString,
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.UpdateKernelImageResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def DeleteKernelImage(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, '/ai.h2o.notebook.v1.KernelImageService/DeleteKernelImage',
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageRequest.SerializeToString,
            ai_dot_h2o_dot_notebook_dot_v1_dot_kernel__image__service__pb2.DeleteKernelImageResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
