com.accendia.iris.server
Interface IApplicationListener


public interface IApplicationListener

This interface must be implemented by application listeners. Application listeners are objects that are invoked by the server when the application is started and must initialize the resources used by the application, for example a database connection pool.

If the application has more than one application listeners the stop() methods are called in the same order of the start() methods calls for the listeners.

Currently the stop() method is called only if the start() method for one of the listeners fails in order to cleanup a partially started application and only if the corresponding start() call succeeded.


Method Summary
 void start()
          Invoked by the server when the application is starting.
 void stop()
          Invoked if the start() invocation for an application listener failed throwing an exception and only if the corresponding start() call for this listener succeeded.
 

Method Detail

start

void start()
           throws ApplicationInitializationException
Invoked by the server when the application is starting.

Throws:
ApplicationInitializationException - If the application can not be started due to an error.

stop

void stop()
Invoked if the start() invocation for an application listener failed throwing an exception and only if the corresponding start() call for this listener succeeded.