toLocal method Null safety

  1. @override
DateTime toLocal()
override

Returns this DateTime value in the local time zone.

Returns this if it is already in the local time zone. Otherwise this method is equivalent to:

DateTime.fromMicrosecondsSinceEpoch(microsecondsSinceEpoch,
                                    isUtc: false)

Implementation

@override
DateTime toLocal() {
  return dateTime.toLocal();
}