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

from . import spaces_pb2 as spaces__pb2


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

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

    Args:
      channel: A grpc.Channel.
    """
    self.CreateSpace = channel.unary_unary(
        '/dialog.Spaces/CreateSpace',
        request_serializer=spaces__pb2.RequestCreateSpace.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.DeleteSpace = channel.unary_unary(
        '/dialog.Spaces/DeleteSpace',
        request_serializer=spaces__pb2.RequestDeleteSpace.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.SetTitle = channel.unary_unary(
        '/dialog.Spaces/SetTitle',
        request_serializer=spaces__pb2.RequestSetTitle.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.SetShortname = channel.unary_unary(
        '/dialog.Spaces/SetShortname',
        request_serializer=spaces__pb2.RequestSetShortname.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.SetAbout = channel.unary_unary(
        '/dialog.Spaces/SetAbout',
        request_serializer=spaces__pb2.RequestSetAbout.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.SetAvatar = channel.unary_unary(
        '/dialog.Spaces/SetAvatar',
        request_serializer=spaces__pb2.RequestSetAvatar.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpace.FromString,
        )
    self.LoadSpaces = channel.unary_unary(
        '/dialog.Spaces/LoadSpaces',
        request_serializer=spaces__pb2.RequestLoadSpaces.SerializeToString,
        response_deserializer=spaces__pb2.ResponseLoadSpaces.FromString,
        )
    self.LoadSpaceMembers = channel.unary_stream(
        '/dialog.Spaces/LoadSpaceMembers',
        request_serializer=spaces__pb2.RequestStreamSpaceMembers.SerializeToString,
        response_deserializer=spaces__pb2.SpaceMemberWithPeer.FromString,
        )
    self.Invite = channel.unary_unary(
        '/dialog.Spaces/Invite',
        request_serializer=spaces__pb2.RequestSpaceInvite.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpaceMember.FromString,
        )
    self.Kick = channel.unary_unary(
        '/dialog.Spaces/Kick',
        request_serializer=spaces__pb2.RequestSpaceKick.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpaceMember.FromString,
        )
    self.Leave = channel.unary_unary(
        '/dialog.Spaces/Leave',
        request_serializer=spaces__pb2.RequestSpaceLeave.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpaceMember.FromString,
        )
    self.GetSpaceInviteUrl = channel.unary_unary(
        '/dialog.Spaces/GetSpaceInviteUrl',
        request_serializer=spaces__pb2.RequestGetSpaceInviteUrl.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpaceInviteUrl.FromString,
        )
    self.RevokeSpaceInviteUrl = channel.unary_unary(
        '/dialog.Spaces/RevokeSpaceInviteUrl',
        request_serializer=spaces__pb2.RequestRevokeSpaceInviteUrl.SerializeToString,
        response_deserializer=spaces__pb2.ResponseSpaceInviteUrl.FromString,
        )


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

  def CreateSpace(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 DeleteSpace(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 SetTitle(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 SetShortname(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 SetAbout(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 SetAvatar(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 LoadSpaces(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 LoadSpaceMembers(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 Invite(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 Kick(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 Leave(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 GetSpaceInviteUrl(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 RevokeSpaceInviteUrl(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_SpacesServicer_to_server(servicer, server):
  rpc_method_handlers = {
      'CreateSpace': grpc.unary_unary_rpc_method_handler(
          servicer.CreateSpace,
          request_deserializer=spaces__pb2.RequestCreateSpace.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'DeleteSpace': grpc.unary_unary_rpc_method_handler(
          servicer.DeleteSpace,
          request_deserializer=spaces__pb2.RequestDeleteSpace.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'SetTitle': grpc.unary_unary_rpc_method_handler(
          servicer.SetTitle,
          request_deserializer=spaces__pb2.RequestSetTitle.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'SetShortname': grpc.unary_unary_rpc_method_handler(
          servicer.SetShortname,
          request_deserializer=spaces__pb2.RequestSetShortname.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'SetAbout': grpc.unary_unary_rpc_method_handler(
          servicer.SetAbout,
          request_deserializer=spaces__pb2.RequestSetAbout.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'SetAvatar': grpc.unary_unary_rpc_method_handler(
          servicer.SetAvatar,
          request_deserializer=spaces__pb2.RequestSetAvatar.FromString,
          response_serializer=spaces__pb2.ResponseSpace.SerializeToString,
      ),
      'LoadSpaces': grpc.unary_unary_rpc_method_handler(
          servicer.LoadSpaces,
          request_deserializer=spaces__pb2.RequestLoadSpaces.FromString,
          response_serializer=spaces__pb2.ResponseLoadSpaces.SerializeToString,
      ),
      'LoadSpaceMembers': grpc.unary_stream_rpc_method_handler(
          servicer.LoadSpaceMembers,
          request_deserializer=spaces__pb2.RequestStreamSpaceMembers.FromString,
          response_serializer=spaces__pb2.SpaceMemberWithPeer.SerializeToString,
      ),
      'Invite': grpc.unary_unary_rpc_method_handler(
          servicer.Invite,
          request_deserializer=spaces__pb2.RequestSpaceInvite.FromString,
          response_serializer=spaces__pb2.ResponseSpaceMember.SerializeToString,
      ),
      'Kick': grpc.unary_unary_rpc_method_handler(
          servicer.Kick,
          request_deserializer=spaces__pb2.RequestSpaceKick.FromString,
          response_serializer=spaces__pb2.ResponseSpaceMember.SerializeToString,
      ),
      'Leave': grpc.unary_unary_rpc_method_handler(
          servicer.Leave,
          request_deserializer=spaces__pb2.RequestSpaceLeave.FromString,
          response_serializer=spaces__pb2.ResponseSpaceMember.SerializeToString,
      ),
      'GetSpaceInviteUrl': grpc.unary_unary_rpc_method_handler(
          servicer.GetSpaceInviteUrl,
          request_deserializer=spaces__pb2.RequestGetSpaceInviteUrl.FromString,
          response_serializer=spaces__pb2.ResponseSpaceInviteUrl.SerializeToString,
      ),
      'RevokeSpaceInviteUrl': grpc.unary_unary_rpc_method_handler(
          servicer.RevokeSpaceInviteUrl,
          request_deserializer=spaces__pb2.RequestRevokeSpaceInviteUrl.FromString,
          response_serializer=spaces__pb2.ResponseSpaceInviteUrl.SerializeToString,
      ),
  }
  generic_handler = grpc.method_handlers_generic_handler(
      'dialog.Spaces', rpc_method_handlers)
  server.add_generic_rpc_handlers((generic_handler,))
