diffInHours method

num diffInHours(
  1. DateTime other, {
  2. bool asFloat = false,
})

Returns the difference between two DateTime objects in hours.

Implementation

num diffInHours(DateTime other, {bool asFloat = false}) {
  return diff(other, unit: TimeUnit.hour, asFloat: asFloat);
}