ChatMessage class
Constructors
- ChatMessage({required String id, required String text, required String senderId, String senderName = "User", required DateTime timestamp, MessageStatus status = MessageStatus.sending, int attempt = 0})
-
ChatMessage.fromJson(Map<
String, dynamic> json) -
factory
Properties
- attempt → int
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- senderId → String
-
final
- senderName → String
-
final
- status → MessageStatus
-
final
- text → String
-
final
- timestamp → DateTime
-
final
Methods
-
copyWith(
{String? id, String? text, String? senderId, String? senderName, DateTime? timestamp, MessageStatus? status, int? attempt}) → ChatMessage -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited