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

from nebius.api.nebius.ai.v1 import job_pb2 as nebius_dot_ai_dot_v1_dot_job__pb2
from nebius.api.nebius.ai.v1 import job_service_pb2 as nebius_dot_ai_dot_v1_dot_job__service__pb2
from nebius.api.nebius.common.v1 import operation_pb2 as nebius_dot_common_dot_v1_dot_operation__pb2


class JobServiceStub(object):
    """Service to create/manage jobs.
    """

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

        Args:
            channel: A grpc.Channel.
        """
        self.Get = channel.unary_unary(
                '/nebius.ai.v1.JobService/Get',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobRequest.SerializeToString,
                response_deserializer=nebius_dot_ai_dot_v1_dot_job__pb2.Job.FromString,
                )
        self.GetByName = channel.unary_unary(
                '/nebius.ai.v1.JobService/GetByName',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobByNameRequest.SerializeToString,
                response_deserializer=nebius_dot_ai_dot_v1_dot_job__pb2.Job.FromString,
                )
        self.List = channel.unary_unary(
                '/nebius.ai.v1.JobService/List',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsRequest.SerializeToString,
                response_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsResponse.FromString,
                )
        self.Create = channel.unary_unary(
                '/nebius.ai.v1.JobService/Create',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.CreateJobRequest.SerializeToString,
                response_deserializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
                )
        self.Delete = channel.unary_unary(
                '/nebius.ai.v1.JobService/Delete',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.DeleteJobRequest.SerializeToString,
                response_deserializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
                )
        self.Cancel = channel.unary_unary(
                '/nebius.ai.v1.JobService/Cancel',
                request_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.CancelJobRequest.SerializeToString,
                response_deserializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
                )


class JobServiceServicer(object):
    """Service to create/manage jobs.
    """

    def Get(self, request, context):
        """Returns the specified job.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def GetByName(self, request, context):
        """Returns the specified job by name.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

    def List(self, request, context):
        """Retrieves a list of jobs.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')

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

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

    def Cancel(self, request, context):
        """Cancels a job.
        """
        context.set_code(grpc.StatusCode.UNIMPLEMENTED)
        context.set_details('Method not implemented!')
        raise NotImplementedError('Method not implemented!')


def add_JobServiceServicer_to_server(servicer, server):
    rpc_method_handlers = {
            'Get': grpc.unary_unary_rpc_method_handler(
                    servicer.Get,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobRequest.FromString,
                    response_serializer=nebius_dot_ai_dot_v1_dot_job__pb2.Job.SerializeToString,
            ),
            'GetByName': grpc.unary_unary_rpc_method_handler(
                    servicer.GetByName,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobByNameRequest.FromString,
                    response_serializer=nebius_dot_ai_dot_v1_dot_job__pb2.Job.SerializeToString,
            ),
            'List': grpc.unary_unary_rpc_method_handler(
                    servicer.List,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsRequest.FromString,
                    response_serializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsResponse.SerializeToString,
            ),
            'Create': grpc.unary_unary_rpc_method_handler(
                    servicer.Create,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.CreateJobRequest.FromString,
                    response_serializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.SerializeToString,
            ),
            'Delete': grpc.unary_unary_rpc_method_handler(
                    servicer.Delete,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.DeleteJobRequest.FromString,
                    response_serializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.SerializeToString,
            ),
            'Cancel': grpc.unary_unary_rpc_method_handler(
                    servicer.Cancel,
                    request_deserializer=nebius_dot_ai_dot_v1_dot_job__service__pb2.CancelJobRequest.FromString,
                    response_serializer=nebius_dot_common_dot_v1_dot_operation__pb2.Operation.SerializeToString,
            ),
    }
    generic_handler = grpc.method_handlers_generic_handler(
            'nebius.ai.v1.JobService', rpc_method_handlers)
    server.add_generic_rpc_handlers((generic_handler,))


 # This class is part of an EXPERIMENTAL API.
class JobService(object):
    """Service to create/manage jobs.
    """

    @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, '/nebius.ai.v1.JobService/Get',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobRequest.SerializeToString,
            nebius_dot_ai_dot_v1_dot_job__pb2.Job.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def GetByName(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, '/nebius.ai.v1.JobService/GetByName',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.GetJobByNameRequest.SerializeToString,
            nebius_dot_ai_dot_v1_dot_job__pb2.Job.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def List(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, '/nebius.ai.v1.JobService/List',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsRequest.SerializeToString,
            nebius_dot_ai_dot_v1_dot_job__service__pb2.ListJobsResponse.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @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, '/nebius.ai.v1.JobService/Create',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.CreateJobRequest.SerializeToString,
            nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Delete(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, '/nebius.ai.v1.JobService/Delete',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.DeleteJobRequest.SerializeToString,
            nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)

    @staticmethod
    def Cancel(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, '/nebius.ai.v1.JobService/Cancel',
            nebius_dot_ai_dot_v1_dot_job__service__pb2.CancelJobRequest.SerializeToString,
            nebius_dot_common_dot_v1_dot_operation__pb2.Operation.FromString,
            options, channel_credentials,
            insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
