/** <p/>
* Interface for object with state and lifecycle
*/
public interface IStateBean {
CharSequence getState(OutFormat format);
StateType getStateType();
String getKey();
void init() throws Exception;
void destroy() throws Exception;
void update(UpdateType type) throws Exception;
}
public enum StateType {
OK(LoggingLevel.INFO),
WARNING(LoggingLevel.WARN),
ERROR(LoggingLevel.ERROR);
StateType(LoggingLevel level) {
this.level = level;
}
public LoggingLevel level;
}