19 lines
372 B
Dart
19 lines
372 B
Dart
class Message {
|
|
String id;
|
|
String receiverName;
|
|
String message;
|
|
DateTime date;
|
|
String senderName;
|
|
bool isMe;
|
|
|
|
Message(
|
|
{this.receiverName, this.message, this.date, this.senderName, this.isMe});
|
|
|
|
bool fromToday() {
|
|
var now = DateTime.now();
|
|
return date.day == now.day &&
|
|
date.month == now.month &&
|
|
date.year == now.year;
|
|
}
|
|
}
|