com.serotonin.m2m2.module
Class RuntimeManagerDefinition

java.lang.Object
  extended by com.serotonin.m2m2.module.ModuleElementDefinition
      extended by com.serotonin.m2m2.module.RuntimeManagerDefinition

public abstract class RuntimeManagerDefinition
extends ModuleElementDefinition

This definition is notified upon initialization and termination of the application.

Author:
Matthew Lohbihler

Constructor Summary
RuntimeManagerDefinition()
           
 
Method Summary
abstract  int getInitializationPriority()
          Determines where in the system initialization this class's initialize method will be called.
abstract  void initialize(boolean safe)
          Run code that initializes things within the module.
abstract  void terminate()
          Run code that terminates things within the module/
 
Methods inherited from class com.serotonin.m2m2.module.ModuleElementDefinition
getModule, initialize, uninstall
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RuntimeManagerDefinition

public RuntimeManagerDefinition()
Method Detail

getInitializationPriority

public abstract int getInitializationPriority()
Determines where in the system initialization this class's initialize method will be called. Values less than or equal to 4 will run before the data sources start. Values grater than or equal to 5 will run after the data sources start. At termination the priorities are reversed.

Returns:
this class's initialization priority

initialize

public abstract void initialize(boolean safe)
Run code that initializes things within the module.

Parameters:
safe - true if the system is starting in "safe mode".

terminate

public abstract void terminate()
Run code that terminates things within the module/