## org.biojava.utils
Class ChangeListener.ChangeEventRecorder

    java.lang.Object
      org.biojava.utils.ChangeAdapter
          org.biojava.utils.ChangeListener.ChangeEventRecorder

All Implemented Interfaces:
  EventListener, ChangeListener

Enclosing interface:
  ChangeListener

    public static class ChangeListener.ChangeEventRecorder

extends ChangeAdapter

A listener that remembers the ChangeEvent of the last change. Mostly for debugging.

Since:
  1.5
Author:
  Mark Schreiber

Nested Class Summary

Nested classes/interfaces inherited from interface org.biojava.utils.ChangeListener
`ChangeListener.AlwaysVetoListener, ChangeListener.ChangeEventRecorder, ChangeListener.LoggingListener`

Field Summary

Fields inherited from interface org.biojava.utils.ChangeListener
`ALWAYS_VETO, LOG_TO_OUT`

Constructor Summary
`ChangeListener.ChangeEventRecorder()`

Method Summary
`ChangeEvent` `getEvent()`
`void` `preChange(ChangeEvent cev)` Called before a change takes place.

Methods inherited from class org.biojava.utils.ChangeAdapter
`postChange`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ChangeListener.ChangeEventRecorder

    public ChangeListener.ChangeEventRecorder()

Method Detail

### getEvent

    public ChangeEvent getEvent()

### preChange

    public void preChange(ChangeEvent cev)
                   throws ChangeVetoException

  Description copied from interface: `ChangeListener`

  Called before a change takes place.

  This is your chance to stop the change by throwing a ChangeVetoException. This method does not indicate that the change will definitely take place, so it is not recomended that you take any positive action within this handler.

  Specified by:
    `preChange` in interface `ChangeListener`
  Overrides:
    `preChange` in class `ChangeAdapter`
  Parameters:
    `cev` - An event encapsulating the change which is about to take place.
  Throws:
    `ChangeVetoException` - Description of Exception