toString method
- @override
override
Returns a string representation of this object.
Implementation
@override
String toString() {
String _addLeadingZeroIfNeeded(int value) {
if (value < 10)
return '0$value';
return value.toString();
}
final String hourLabel = _addLeadingZeroIfNeeded(hour);
final String minuteLabel = _addLeadingZeroIfNeeded(minute);
return '$TimeOfDay($hourLabel:$minuteLabel)';
}