哦,好象是这样的。 “When scheduling a task for repeated execution, you should use one of the schedule methods when smoothness is important and a scheduleAtFixedRate method when time synchronization is more important. For example, the AnnoyingBeep program uses the schedule method, which means that the annoying beeps will all be at least 1 second apart. If one beep is late for any reason, all subsequent beeps will be delayed. If we decide that the AnnoyingBeep program should exit exactly 3 seconds after the first beep¡ªeven if it means that two beeps might occur close together if a beep is delayed for any reason¡ªwe should use the scheduleAtFixedRate method instead. ”
如果run()在时间周期之内完成,那么下一次的信号就会在下一次预定的时间产生。但是,如果run()无法在时间周期之内完成,那么等到run完成之后,下一次的信号产生就尽量赶上原本应该产生信号的时间。
“When scheduling a task for repeated execution,
you should use one of the schedule methods when smoothness is important
and a scheduleAtFixedRate method when time synchronization is more important.
For example, the AnnoyingBeep program uses the schedule method,
which means that the annoying beeps will all be at least 1 second apart.
If one beep is late for any reason, all subsequent beeps will be delayed.
If we decide that the AnnoyingBeep program should exit exactly 3 seconds after the first beep¡ªeven if it means
that two beeps might occur close together if a beep is delayed
for any reason¡ªwe should use the scheduleAtFixedRate method instead. ”