org.jscience.util
Class ChangeVetoException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.jscience.util.ChangeVetoException
All Implemented Interfaces:
java.io.Serializable

public class ChangeVetoException
extends java.lang.Exception

Exception which is thrown when a ChangeListener does not wish a change to take place.

Since:
1.1
See Also:
Serialized Form

Constructor Summary
ChangeVetoException()
          Creates a new ChangeVetoException object.
ChangeVetoException(ChangeEvent change)
          Construct an exception to veto a change without explanation.
ChangeVetoException(ChangeEvent change, java.lang.String reason)
          Construct an exception to veto a change for a specified reason.
ChangeVetoException(java.lang.String reason)
          Create an exception with a detail message
ChangeVetoException(java.lang.String reason, java.lang.Throwable cause)
          Creates a new ChangeVetoException object.
ChangeVetoException(java.lang.Throwable ex, ChangeEvent change)
          Propogate an exception without (additional) explanation.
ChangeVetoException(java.lang.Throwable ex, ChangeEvent change, java.lang.String reason)
          Propogate an exception, giving a detail message
ChangeVetoException(java.lang.Throwable ex, java.lang.String reason)
          Deprecated. use new ChangeVetoException(reason, ex);
 
Method Summary
 ChangeEvent getChangeEvent()
          Return the ChangeEvent which is being vetoed.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ChangeVetoException

public ChangeVetoException()
Creates a new ChangeVetoException object.


ChangeVetoException

public ChangeVetoException(ChangeEvent change)
Construct an exception to veto a change without explanation.

Parameters:
change - An event which is being vetoed.

ChangeVetoException

public ChangeVetoException(java.lang.String reason)
Create an exception with a detail message

Parameters:
reason - A detail message.

ChangeVetoException

public ChangeVetoException(ChangeEvent change,
                           java.lang.String reason)
Construct an exception to veto a change for a specified reason.

Parameters:
change - An event which is being vetoed.
reason - A detail message.

ChangeVetoException

public ChangeVetoException(java.lang.Throwable ex,
                           ChangeEvent change)
Propogate an exception without (additional) explanation.

Parameters:
ex - A parent exception
change - An event which is being vetoed.

ChangeVetoException

public ChangeVetoException(java.lang.Throwable ex,
                           java.lang.String reason)
Deprecated. use new ChangeVetoException(reason, ex);

Propogate an exception, giving a detail message

Parameters:
ex - A parent exception
reason - A detail message.

ChangeVetoException

public ChangeVetoException(java.lang.String reason,
                           java.lang.Throwable cause)
Creates a new ChangeVetoException object.

Parameters:
reason - DOCUMENT ME!
cause - DOCUMENT ME!

ChangeVetoException

public ChangeVetoException(java.lang.Throwable ex,
                           ChangeEvent change,
                           java.lang.String reason)
Propogate an exception, giving a detail message

Parameters:
ex - A parent exception
change - An event which is being vetoed.
reason - A detail message.
Method Detail

getChangeEvent

public ChangeEvent getChangeEvent()
Return the ChangeEvent which is being vetoed.

Returns:
The ChangeEvent value