toTimeOfDayAuto method

TimeOfDay toTimeOfDayAuto()

Smart detection: tries 24h first, then 12h

Implementation

TimeOfDay toTimeOfDayAuto() {
  try {
    return toTimeOfDay24();
  } on FormatException {
    return toTimeOfDay12();
  }
}