difference static method
Implementation
static Duration difference(time) {
if (time == null) {
return const Duration();
}
var dateTime = DateUtil.getDateTimeByMs(time);
DateTime today = DateTime.now();
Duration difference = dateTime.difference(today);
return difference;
}