isThisSecond method
Returns true
if the second is the same as a specific dateTime
or the current time.
特定のdateTime
もしくは現在時間と同じ秒の場合はtrue
を返します。
Implementation
bool isThisSecond([DateTime? dateTime]) {
dateTime ??= DateTime.now();
return year == dateTime.year &&
month == dateTime.month &&
day == dateTime.day &&
hour == dateTime.hour &&
minute == dateTime.minute &&
second == dateTime.second;
}