toLocal method Null safety

DateTime? toLocal()

Returns this DateTime value in the local time zone.

Returns null if this is null

Returns this if it is already in the local time zone.

Implementation

DateTime? toLocal() => _value?.toLocal();