Sea 0.4.0

gov.lbl.dsd.sea.event
Class IllegalEventException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byjava.lang.RuntimeException
              extended bygov.lbl.dsd.sea.event.ExceptionEvent
                  extended bygov.lbl.dsd.sea.event.IllegalEventException
All Implemented Interfaces:
Serializable

public class IllegalEventException
extends ExceptionEvent

A runtime exception similar in spirit to the classic IllegalArgumentException, to be thrown when EventHandler.handle(java.lang.Object) cannot handle an event of a certain kind. Useful, since most EventHandlers cannot handle arbitrary objects but can only handle events of certain classes with certain parameter constraints.

If appropriate, you can enqueue an instance of this class onto a stage.

Version:
$Revision: 1.2 $, $Date: 2004/05/21 20:34:11 $
See Also:
Serialized Form

Constructor Summary
IllegalEventException(Object causingEvent, Stage source)
          Constructs a new exception with the specified detail message and causing event.
IllegalEventException(String message, Object causingEvent, Stage source)
          Constructs a new exception with the specified detail message and causing event.
 
Methods inherited from class gov.lbl.dsd.sea.event.ExceptionEvent
getCausingEvent, getSource, toString
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IllegalEventException

public IllegalEventException(Object causingEvent,
                             Stage source)
Constructs a new exception with the specified detail message and causing event.

Parameters:
causingEvent - the event that caused the exception.
source - the stage that could not properly handle the causing event.

IllegalEventException

public IllegalEventException(String message,
                             Object causingEvent,
                             Stage source)
Constructs a new exception with the specified detail message and causing event.

Parameters:
message - the detail message. The detail message is saved for later retrieval by the Throwable.getMessage()method.
causingEvent - the event that caused the exception.
source - the stage that could not properly handle the causing event.

Sea 0.4.0