DraftMessage constructor
DraftMessage({
- String? id,
- String? text,
- String type = MessageType.regular,
- List<
Attachment> attachments = const [], - String? parentId,
- bool? showInChannel,
- List<
User> mentionedUsers = const [], - Message? quotedMessage,
- String? quotedMessageId,
- bool silent = false,
- String? command,
- Poll? poll,
- String? pollId,
- Map<
String, Object?> extraData = const {},
Creates a new draft message.
Implementation
DraftMessage({
String? id,
this.text,
String type = MessageType.regular,
this.attachments = const [],
this.parentId,
this.showInChannel,
this.mentionedUsers = const [],
this.quotedMessage,
String? quotedMessageId,
this.silent = false,
this.command,
this.poll,
String? pollId,
this.extraData = const {},
}) : id = id ?? const Uuid().v4(),
type = MessageType(type),
_quotedMessageId = quotedMessageId,
_pollId = pollId;