Package org.opennms.netmgt.threshd
Class ThresholdingSetImpl
- java.lang.Object
-
- org.opennms.netmgt.threshd.ThresholdingSetImpl
-
- All Implemented Interfaces:
ThresholdingSet
public class ThresholdingSetImpl extends java.lang.Object implements ThresholdingSet
Abstract ThresholdingSet class.
- Author:
- Alejandro Galue
-
-
Field Summary
Fields Modifier and Type Field Description protected ThresholdingEventProxym_eventProxyprotected java.lang.Stringm_hostAddressprotected intm_nodeIdprotected RrdRepositorym_repositoryprotected ResourceStorageDaom_resourceStorageDaoprotected java.util.List<java.lang.String>m_scheduledOutagesprotected java.lang.Stringm_serviceNameprotected java.util.List<ThresholdGroup>m_thresholdGroupsprotected ThresholdsDaom_thresholdsDao
-
Constructor Summary
Constructors Constructor Description ThresholdingSetImpl(int nodeId, java.lang.String hostAddress, java.lang.String serviceName, RrdRepository repository, ServiceParameters svcParams, ResourceStorageDao resourceStorageDao, ThresholdingEventProxy eventProxy, ThresholdingSession thresholdingSession, ReadableThreshdDao threshdDao, ReadableThresholdingDao thresholdingDao, ReadablePollOutagesDao pollOutagesDao, IfLabel ifLabelDao, EntityScopeProvider entityScopeProvider)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<Event>applyThresholds(CollectionResource resource, java.util.Map<java.lang.String,CollectionAttribute> attributesMap, java.util.Date collectionTimestamp, java.lang.Long sequenceNumber)protected java.util.List<Event>applyThresholds(CollectionResourceWrapper resourceWrapper, java.util.Map<java.lang.String,CollectionAttribute> attributesMap)intgetNodeId()java.util.List<java.lang.String>getscheduledOutages()java.util.List<ThresholdGroup>getThresholdGroups()booleanhasThresholds()booleanhasThresholds(CollectionAttribute attribute)protected voidinitialize()protected voidinitThresholdsDao()booleanisNodeInOutage()protected booleanpassedThresholdFilters(CollectionResourceWrapper resource, ThresholdEntity thresholdEntity)voidreinitialize()voidsetCounterReset(boolean counterReset)java.lang.StringtoString()protected voidupdateScheduledOutages()
-
-
-
Field Detail
-
m_nodeId
protected final int m_nodeId
-
m_hostAddress
protected final java.lang.String m_hostAddress
-
m_serviceName
protected final java.lang.String m_serviceName
-
m_repository
protected final RrdRepository m_repository
-
m_thresholdsDao
protected ThresholdsDao m_thresholdsDao
-
m_eventProxy
protected ThresholdingEventProxy m_eventProxy
-
m_resourceStorageDao
protected ResourceStorageDao m_resourceStorageDao
-
m_thresholdGroups
protected final java.util.List<ThresholdGroup> m_thresholdGroups
-
m_scheduledOutages
protected final java.util.List<java.lang.String> m_scheduledOutages
-
-
Constructor Detail
-
ThresholdingSetImpl
public ThresholdingSetImpl(int nodeId, java.lang.String hostAddress, java.lang.String serviceName, RrdRepository repository, ServiceParameters svcParams, ResourceStorageDao resourceStorageDao, ThresholdingEventProxy eventProxy, ThresholdingSession thresholdingSession, ReadableThreshdDao threshdDao, ReadableThresholdingDao thresholdingDao, ReadablePollOutagesDao pollOutagesDao, IfLabel ifLabelDao, EntityScopeProvider entityScopeProvider) throws ThresholdInitializationException- Throws:
ThresholdInitializationException
-
-
Method Detail
-
initialize
protected void initialize() throws ThresholdInitializationException- Throws:
ThresholdInitializationException
-
reinitialize
public void reinitialize()
- Specified by:
reinitializein interfaceThresholdingSet
-
hasThresholds
public boolean hasThresholds()
-
isNodeInOutage
public final boolean isNodeInOutage()
-
applyThresholds
protected final java.util.List<Event> applyThresholds(CollectionResourceWrapper resourceWrapper, java.util.Map<java.lang.String,CollectionAttribute> attributesMap)
-
passedThresholdFilters
protected boolean passedThresholdFilters(CollectionResourceWrapper resource, ThresholdEntity thresholdEntity)
-
initThresholdsDao
protected final void initThresholdsDao() throws ThresholdInitializationException- Throws:
ThresholdInitializationException
-
updateScheduledOutages
protected void updateScheduledOutages()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
setCounterReset
public void setCounterReset(boolean counterReset)
-
hasThresholds
public boolean hasThresholds(CollectionAttribute attribute)
-
applyThresholds
public java.util.List<Event> applyThresholds(CollectionResource resource, java.util.Map<java.lang.String,CollectionAttribute> attributesMap, java.util.Date collectionTimestamp, java.lang.Long sequenceNumber)
-
getThresholdGroups
public java.util.List<ThresholdGroup> getThresholdGroups()
-
getNodeId
public int getNodeId()
-
getscheduledOutages
public java.util.List<java.lang.String> getscheduledOutages()
-
-