createGroup method

  1. @override
void createGroup({
  1. required String name,
  2. required List<RoomMember> members,
  3. String? password,
})
override

Implementation

@override
void createGroup(
    {required String name,
    required List<RoomMember> members,
    String? password}) {
  String id = const Uuid().v4();
  GroupCrudMessage msg = GroupCrudMessage(
      id: id,
      type: MessageType.addGroup,
      name: name,
      sendTime: 0,
      members: members);

  String topic = id.toGroupCrudTopic;
  clientHandler.sendPayload(msg.toJson().toString(), topic);
}