Package org.opennms.features.ifttt
Class IfTttDaemon
- java.lang.Object
-
- org.opennms.features.ifttt.IfTttDaemon
-
public class IfTttDaemon extends Object
This class represents a daemon for polling alarms in order to generate IFTTT events.
-
-
Constructor Summary
Constructors Constructor Description IfTttDaemon(AlarmDao alarmDao, org.springframework.transaction.support.TransactionOperations transactionOperations)
Constructor to create the daemon instance.IfTttDaemon(AlarmDao alarmDao, org.springframework.transaction.support.TransactionOperations transactionOperations, File ifTttConfigFile)
Constructor to create the daemon instance with a given configuraton file
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
fireIfTttTriggerSet(IfTttConfig ifTttConfig, String filterKey, String name, VariableNameExpansion variableNameExpansion)
Executes a configured trigger set with a given String value.void
start()
Starts the daemonvoid
stop()
Stops the daemon
-
-
-
Constructor Detail
-
IfTttDaemon
public IfTttDaemon(AlarmDao alarmDao, org.springframework.transaction.support.TransactionOperations transactionOperations, File ifTttConfigFile)
Constructor to create the daemon instance with a given configuraton file- Parameters:
alarmDao
- the alarm dao instance to be usedtransactionOperations
- the transaction template to be usedifTttConfigFile
- the configuration file to be used
-
IfTttDaemon
public IfTttDaemon(AlarmDao alarmDao, org.springframework.transaction.support.TransactionOperations transactionOperations)
Constructor to create the daemon instance.- Parameters:
alarmDao
- the alarm dao instance to be usedtransactionOperations
- the transaction template to be used
-
-
Method Detail
-
start
public void start()
Starts the daemon
-
stop
public void stop()
Stops the daemon
-
fireIfTttTriggerSet
protected void fireIfTttTriggerSet(IfTttConfig ifTttConfig, String filterKey, String name, VariableNameExpansion variableNameExpansion)
Executes a configured trigger set with a given String value.- Parameters:
ifTttConfig
- the IFTTT config instancefilterKey
- the filtername
- the event namevariableNameExpansion
- the VariableNameExpansion to be used
-
-