toDateTime method

DateTime toDateTime({
  1. bool utc = false,
})

Convert to a DateTime.

Implementation

DateTime toDateTime({bool utc = false}) {
  if (utc) {
    return DateTime.utc(year, month, day);
  } else {
    return DateTime(year, month, day);
  }
}