net.xoetrope.optional.svg.tinyline
Class SVGEventQueue

java.lang.Object
  extended by net.xoetrope.optional.svg.tinyline.SVGEventQueue

public class SVGEventQueue
extends java.lang.Object

The SVGEventQueue is a class that queues SVG events.


Constructor Summary
SVGEventQueue()
          Creates a new SVGEventQueue object.
 
Method Summary
 SVGEvent getNextEvent()
          Remove an event from the queue and return it.
 void handleEvent(SVGEvent theEvent)
          Dispatch an event to the eventHandler.
 SVGEvent peekEvent()
          Return the first event without removing it.
 void postEvent(SVGEvent theEvent)
          Post an event to the EventQueue.
 void reset()
          Resets the SVGEventQueue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SVGEventQueue

public SVGEventQueue()
Creates a new SVGEventQueue object.

Method Detail

reset

public void reset()
Resets the SVGEventQueue.


getNextEvent

public SVGEvent getNextEvent()
                      throws java.lang.InterruptedException
Remove an event from the queue and return it. This method will block until an event has been posted by another thread.

Returns:
the next SVGEvent
Throws:
java.lang.InterruptedException - if another thread has interrupted this thread.

handleEvent

public void handleEvent(SVGEvent theEvent)
Dispatch an event to the eventHandler.

Parameters:
theEvent - an instance of SVGEvent, or a subclass of it.

postEvent

public void postEvent(SVGEvent theEvent)
Post an event to the EventQueue.

Parameters:
theEvent - an instance of SVGEvent, or a subclass of it.

peekEvent

public SVGEvent peekEvent()
Return the first event without removing it.