Lines Matching refs:delay

64  *  int delay = 1000; //milliseconds
70 * new Timer(delay, taskPerformer).start();</pre>
73 * {@code Timers} are constructed by specifying both a delay parameter
74 * and an {@code ActionListener}. The delay parameter is used
75 * to set both the initial delay and the delay between event
77 * it waits for the initial delay before firing its
80 * every time the between-event delay has elapsed, until it
83 * After construction, the initial delay and the between-event
84 * delay can be changed independently, and additional
172 private volatile int initialDelay, delay;
190 * Creates a {@code Timer} and initializes both the initial delay and
191 * between-event delay to {@code delay} milliseconds. If {@code delay}
196 * @param delay milliseconds for the initial and between-event delay
203 public Timer(int delay, ActionListener listener) {
205 this.delay = delay;
206 this.initialDelay = delay;
390 * Sets the <code>Timer</code>'s between-event delay, the number of milliseconds
391 * between successive action events. This does not affect the initial delay
394 * @param delay the delay in milliseconds
397 public void setDelay(int delay) {
398 if (delay < 0) {
399 throw new IllegalArgumentException("Invalid delay: " + delay);
402 this.delay = delay;
408 * Returns the delay, in milliseconds,
415 return delay;
420 * Sets the <code>Timer</code>'s initial delay, the time
423 * is set to be the same as the between-event delay,
425 * by changes to the between-event delay.
427 * @param initialDelay the initial delay, in milliseconds
432 throw new IllegalArgumentException("Invalid initial delay: " +
442 * Returns the <code>Timer</code>'s initial delay.
487 * events with no delay between them. Coalescing avoids this situation
586 * it to fire with its initial delay.
639 timer.delay = delay;