from static method

int from(
  1. int hour, [
  2. int minute = 0,
  3. int second = 0,
  4. int millisecond = 0,
])

Converts the given duration into milliseconds.

Implementation

static int from(int hour, [int minute = 0, int second = 0, int millisecond = 0]) =>
    hour * Hour.milliseconds + minute * Minute.milliseconds +
        second * Second.milliseconds + millisecond;