org.oddjob.beanbus
Interface BusListener

All Superinterfaces:
EventListener
All Known Implementing Classes:
BusListenerAdapter

public interface BusListener
extends EventListener

Something that listens to BeanBus events broadcast by an BusConductor.

Author:
rob

Method Summary
 void busCrashed(BusEvent event)
          Called if the bus has crashed.
 void busStarting(BusEvent event)
          The bus is starting.
 void busStopping(BusEvent event)
          The bus is stopping.
 void busStopRequested(BusEvent event)
           
 void busTerminated(BusEvent event)
          The bus has terminated.
 void tripBeginning(BusEvent event)
          Stage starting.
 void tripEnding(BusEvent event)
          Stage complete.
 

Method Detail

busStarting

void busStarting(BusEvent event)
                 throws BusCrashException
The bus is starting. Called before any beans have gone anywhere.

Parameters:
event -
Throws:
BusCrashException

tripBeginning

void tripBeginning(BusEvent event)
                   throws BusCrashException
Stage starting.

Parameters:
event -
Throws:
BusCrashException

tripEnding

void tripEnding(BusEvent event)
                throws BusCrashException
Stage complete.

Parameters:
event -
Throws:
BusCrashException

busStopping

void busStopping(BusEvent event)
                 throws BusCrashException
The bus is stopping. Called when all the beans have arrived at their destination. This notification will only be received if the bus hasn't crashed. The bus can crash while stopping.

Parameters:
event -
Throws:
BusCrashException

busStopRequested

void busStopRequested(BusEvent event)
Parameters:
event -

busTerminated

void busTerminated(BusEvent event)
The bus has terminated. Called after either a busStopping or busCrashed notification. Always called.

Parameters:
event -

busCrashed

void busCrashed(BusEvent event)
Called if the bus has crashed. The bus can crash while starting, stopping and any time in between.

Parameters:
event -