# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
import grpc

from yandex.cloud.k8s.v1 import cluster_pb2 as yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__pb2
from yandex.cloud.k8s.v1 import cluster_service_pb2 as yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2
from yandex.cloud.operation import operation_pb2 as yandex_dot_cloud_dot_operation_dot_operation__pb2


class ClusterServiceStub(object):
  """A set of methods for managing Kubernetes cluster.
  """

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

    Args:
      channel: A grpc.Channel.
    """
    self.Get = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Get',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.GetClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__pb2.Cluster.FromString,
        )
    self.List = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/List',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClustersRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClustersResponse.FromString,
        )
    self.Create = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Create',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.CreateClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
        )
    self.Update = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Update',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.UpdateClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
        )
    self.Delete = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Delete',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.DeleteClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
        )
    self.Stop = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Stop',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.StopClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
        )
    self.Start = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/Start',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.StartClusterRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.FromString,
        )
    self.ListNodeGroups = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/ListNodeGroups',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodeGroupsRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodeGroupsResponse.FromString,
        )
    self.ListOperations = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/ListOperations',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterOperationsRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterOperationsResponse.FromString,
        )
    self.ListNodes = channel.unary_unary(
        '/yandex.cloud.k8s.v1.ClusterService/ListNodes',
        request_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodesRequest.SerializeToString,
        response_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodesResponse.FromString,
        )


class ClusterServiceServicer(object):
  """A set of methods for managing Kubernetes cluster.
  """

  def Get(self, request, context):
    """Returns the specified Kubernetes cluster.

    To get the list of available Kubernetes cluster, make a [List] request.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def List(self, request, context):
    """Retrieves the list of Kubernetes cluster in the specified folder.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def Create(self, request, context):
    """Creates a Kubernetes cluster in the specified folder.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def Update(self, request, context):
    """Updates the specified Kubernetes cluster.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

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

  def Stop(self, request, context):
    """Stops the specified Kubernetes cluster.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def Start(self, request, context):
    """Starts the specified Kubernetes cluster.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def ListNodeGroups(self, request, context):
    """Lists nodegroup for the specified Kubernetes cluster.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def ListOperations(self, request, context):
    """Lists operations for the specified Kubernetes cluster.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def ListNodes(self, request, context):
    """Lists cluster's nodes.
    """
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')


def add_ClusterServiceServicer_to_server(servicer, server):
  rpc_method_handlers = {
      'Get': grpc.unary_unary_rpc_method_handler(
          servicer.Get,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.GetClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__pb2.Cluster.SerializeToString,
      ),
      'List': grpc.unary_unary_rpc_method_handler(
          servicer.List,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClustersRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClustersResponse.SerializeToString,
      ),
      'Create': grpc.unary_unary_rpc_method_handler(
          servicer.Create,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.CreateClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
      ),
      'Update': grpc.unary_unary_rpc_method_handler(
          servicer.Update,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.UpdateClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
      ),
      'Delete': grpc.unary_unary_rpc_method_handler(
          servicer.Delete,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.DeleteClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
      ),
      'Stop': grpc.unary_unary_rpc_method_handler(
          servicer.Stop,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.StopClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
      ),
      'Start': grpc.unary_unary_rpc_method_handler(
          servicer.Start,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.StartClusterRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_operation_dot_operation__pb2.Operation.SerializeToString,
      ),
      'ListNodeGroups': grpc.unary_unary_rpc_method_handler(
          servicer.ListNodeGroups,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodeGroupsRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodeGroupsResponse.SerializeToString,
      ),
      'ListOperations': grpc.unary_unary_rpc_method_handler(
          servicer.ListOperations,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterOperationsRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterOperationsResponse.SerializeToString,
      ),
      'ListNodes': grpc.unary_unary_rpc_method_handler(
          servicer.ListNodes,
          request_deserializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodesRequest.FromString,
          response_serializer=yandex_dot_cloud_dot_k8s_dot_v1_dot_cluster__service__pb2.ListClusterNodesResponse.SerializeToString,
      ),
  }
  generic_handler = grpc.method_handlers_generic_handler(
      'yandex.cloud.k8s.v1.ClusterService', rpc_method_handlers)
  server.add_generic_rpc_handlers((generic_handler,))
