isAfternoon method

bool isAfternoon()

Check if the date is in the afternoon.

Implementation

bool isAfternoon() {
  if (this == null) return false;
  if (this?.hour == null) return false;
  return this!.hour >= 12 && this!.hour < 18;
}