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

from google.protobuf import empty_pb2 as google_dot_protobuf_dot_empty__pb2
import slice_pb2 as slice__pb2


class SliceServiceStub(object):
  # missing associated documentation comment in .proto file
  pass

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

    Args:
      channel: A grpc.Channel.
    """
    self.CreateUpdateSlice = channel.unary_unary(
        '/slice.SliceService/CreateUpdateSlice',
        request_serializer=slice__pb2.TransportSlice.SerializeToString,
        response_deserializer=slice__pb2.SliceStatus.FromString,
        )
    self.DeleteSlice = channel.unary_unary(
        '/slice.SliceService/DeleteSlice',
        request_serializer=slice__pb2.TransportSlice.SerializeToString,
        response_deserializer=google_dot_protobuf_dot_empty__pb2.Empty.FromString,
        )


class SliceServiceServicer(object):
  # missing associated documentation comment in .proto file
  pass

  def CreateUpdateSlice(self, request, context):
    # missing associated documentation comment in .proto file
    pass
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')

  def DeleteSlice(self, request, context):
    # missing associated documentation comment in .proto file
    pass
    context.set_code(grpc.StatusCode.UNIMPLEMENTED)
    context.set_details('Method not implemented!')
    raise NotImplementedError('Method not implemented!')


def add_SliceServiceServicer_to_server(servicer, server):
  rpc_method_handlers = {
      'CreateUpdateSlice': grpc.unary_unary_rpc_method_handler(
          servicer.CreateUpdateSlice,
          request_deserializer=slice__pb2.TransportSlice.FromString,
          response_serializer=slice__pb2.SliceStatus.SerializeToString,
      ),
      'DeleteSlice': grpc.unary_unary_rpc_method_handler(
          servicer.DeleteSlice,
          request_deserializer=slice__pb2.TransportSlice.FromString,
          response_serializer=google_dot_protobuf_dot_empty__pb2.Empty.SerializeToString,
      ),
  }
  generic_handler = grpc.method_handlers_generic_handler(
      'slice.SliceService', rpc_method_handlers)
  server.add_generic_rpc_handlers((generic_handler,))
