124 * <a href="http://docs.oracle.com/javase/tutorial/uiswing/misc/timer.html"
125 * target = "_top">How to Use Timers</a>,
126 * a section in <em>The Java Tutorial.</em>
127 * For more examples and help in choosing between
128 * this <code>Timer</code> class and
129 * <code>java.util.Timer</code>,
130 * see
131 * <a href="http://java.sun.com/products/jfc/tsc/articles/timer/"
132 * target="_top">Using Timers in Swing Applications</a>,
133 * an article in <em>The Swing Connection.</em>
134 * <p>
135 * <strong>Warning:</strong>
136 * Serialized objects of this class will not be compatible with
137 * future Swing releases. The current serialization support is
138 * appropriate for short term storage or RMI between applications running
139 * the same version of Swing. As of 1.4, support for long term storage
140 * of all JavaBeans™
141 * has been added to the <code>java.beans</code> package.
142 * Please see {@link java.beans.XMLEncoder}.
143 *
144 * @see java.util.Timer <code>java.util.Timer</code>
145 *
146 *
147 * @author Dave Moore
148 * @since 1.2
149 */
150 @SuppressWarnings("serial")
151 public class Timer implements Serializable
152 {
153 /*
154 * NOTE: all fields need to be handled in readResolve
155 */
156
157 /**
158 * The collection of registered listeners
159 */
160 protected EventListenerList listenerList = new EventListenerList();
161
162 // The following field strives to maintain the following:
163 // If coalesce is true, only allow one Runnable to be queued on the
164 // EventQueue and be pending (ie in the process of notifying the
|
124 * <a href="http://docs.oracle.com/javase/tutorial/uiswing/misc/timer.html"
125 * target = "_top">How to Use Timers</a>,
126 * a section in <em>The Java Tutorial.</em>
127 * For more examples and help in choosing between
128 * this <code>Timer</code> class and
129 * <code>java.util.Timer</code>,
130 * see
131 * <a href="http://java.sun.com/products/jfc/tsc/articles/timer/"
132 * target="_top">Using Timers in Swing Applications</a>,
133 * an article in <em>The Swing Connection.</em>
134 * <p>
135 * <strong>Warning:</strong>
136 * Serialized objects of this class will not be compatible with
137 * future Swing releases. The current serialization support is
138 * appropriate for short term storage or RMI between applications running
139 * the same version of Swing. As of 1.4, support for long term storage
140 * of all JavaBeans™
141 * has been added to the <code>java.beans</code> package.
142 * Please see {@link java.beans.XMLEncoder}.
143 *
144 * @see java.util.Timer
145 *
146 *
147 * @author Dave Moore
148 * @since 1.2
149 */
150 @SuppressWarnings("serial")
151 public class Timer implements Serializable
152 {
153 /*
154 * NOTE: all fields need to be handled in readResolve
155 */
156
157 /**
158 * The collection of registered listeners
159 */
160 protected EventListenerList listenerList = new EventListenerList();
161
162 // The following field strives to maintain the following:
163 // If coalesce is true, only allow one Runnable to be queued on the
164 // EventQueue and be pending (ie in the process of notifying the
|