ChatMessage constructor
ChatMessage({
- required String id,
- required String content,
- required String role,
- required DateTime timestamp,
- bool isLoading = false,
- String? imageUrl,
- Uint8List? imageBytes,
- String? fileName,
- List<
QuickReplyButton> quickReplies = const [], - MessageType type = MessageType.text,
- bool isThinking = false,
- String? thinkingStatus,
- bool isStreaming = false,
- Map<
String, dynamic> ? uiComponentData, - String? audioPath,
- int? audioDuration,
- String? userSelection,
- int? messageIndex,
Implementation
ChatMessage({
required this.id,
required this.content,
required this.role,
required this.timestamp,
this.isLoading = false,
this.imageUrl,
this.imageBytes,
this.fileName,
this.quickReplies = const [],
this.type = MessageType.text,
this.isThinking = false,
this.thinkingStatus,
this.isStreaming = false,
this.uiComponentData,
this.audioPath,
this.audioDuration,
this.userSelection,
this.messageIndex,
});