Class AbstractAlarmServer<S,T>

java.lang.Object
com.google.common.util.concurrent.AbstractService
org.yamcs.alarms.AbstractAlarmServer<S,T>
All Implemented Interfaces:
com.google.common.util.concurrent.Service
Direct Known Subclasses:
AbstractAlarmMirrorServer, AlarmServer

public abstract class AbstractAlarmServer<S,T> extends com.google.common.util.concurrent.AbstractService
  • Field Details

  • Constructor Details

    • AbstractAlarmServer

      public AbstractAlarmServer(String yamcsInstance)
  • Method Details

    • getActiveAlarms

      public Map<S,ActiveAlarm<T>> getActiveAlarms()
      Returns the current set of active alarms
    • addAlarmListener

      public Map<S,ActiveAlarm<T>> addAlarmListener(AlarmListener<T> listener)
      Register for alarm notices
      Returns:
      the current set of active alarms
    • removeAlarmListener

      public void removeAlarmListener(AlarmListener<T> listener)
    • loadAlarmsFromDb

      protected void loadAlarmsFromDb(double numDays, Map<S,ActiveAlarm<T>> alarms)
    • getLock

      protected Object getLock(S alarmId)
    • addActiveAlarmFromTuple

      protected abstract void addActiveAlarmFromTuple(Mdb mdb, Tuple t, Map<S,ActiveAlarm<T>> alarms)
    • getSubject

      protected abstract S getSubject(T value)
    • alarmTableName

      protected abstract String alarmTableName()
    • getColNameLastEvent

      protected abstract String getColNameLastEvent()
    • getColNameSeverityIncreased

      protected abstract String getColNameSeverityIncreased()