Package org.opennms.netmgt.mock
Class NotificationAnticipator
- java.lang.Object
-
- org.opennms.netmgt.mock.NotificationAnticipator
-
public class NotificationAnticipator extends Object
- Author:
- brozow
-
-
Constructor Summary
Constructors Constructor Description NotificationAnticipator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidanticipateNotification(MockNotification mn)Collection<MockNotification>getAnticipatedNotifications()longgetExpectedDifference()Collection<MockNotification>getUnanticipated()voidnotificationReceived(MockNotification mn)voidreset()voidsetExpectedDifference(long expectedDiff)voidverifyAnticipated(long lastNotifyTime, long waitTime, long sleepTime)Collection<MockNotification>waitForAnticipated(long millis)
-
-
-
Method Detail
-
setExpectedDifference
public void setExpectedDifference(long expectedDiff)
- Parameters:
expectedDiff-
-
getExpectedDifference
public long getExpectedDifference()
- Returns:
-
anticipateNotification
public void anticipateNotification(MockNotification mn)
- Parameters:
event-
-
notificationReceived
public void notificationReceived(MockNotification mn)
- Parameters:
event-
-
getAnticipatedNotifications
public Collection<MockNotification> getAnticipatedNotifications()
-
reset
public void reset()
-
getUnanticipated
public Collection<MockNotification> getUnanticipated()
- Returns:
-
waitForAnticipated
public Collection<MockNotification> waitForAnticipated(long millis)
- Parameters:
i-- Returns:
-
verifyAnticipated
public void verifyAnticipated(long lastNotifyTime, long waitTime, long sleepTime)
-
-