runCommand method

void runCommand(
  1. Command command
)

Run the given command.

Implementation

void runCommand(final Command command) {
  final onStart = command.onStart;
  if (onStart != null) {
    onStart();
    final interval = command.interval;
    if (interval != null) {
      final nextRun = getCommandNextRun(command);
      if (nextRun == null) {
        commandNextRuns.add(NextRun(command));
      } else {
        nextRun.runAfter -= interval;
      }
    }
  }
}