java.lang.Object
org.snmp4j.mp.CounterSupport
The
CounterSupport
class provides support to fire CounterEvent
to registered listeners.- Version:
- 3.0
- Author:
- Frank Fock
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addCounterListener
(CounterListener listener) Adds aCounterListener
.void
fireIncrementCounter
(CounterEvent event) Inform all registered listeners that the supplied counter needs to be incremented.static CounterSupport
Gets the counter support singleton.void
removeCounterListener
(CounterListener listener) Removes a previously addedCounterListener
.
-
Field Details
-
instance
-
-
Constructor Details
-
CounterSupport
public CounterSupport()Create a newCounterSupport
object.
-
-
Method Details
-
getInstance
Gets the counter support singleton.- Returns:
- the
CounterSupport
instance.
-
addCounterListener
Adds aCounterListener
.- Parameters:
listener
- aCounterListener
instance that needs to be informed when a counter needs to be incremented.
-
removeCounterListener
Removes a previously addedCounterListener
.- Parameters:
listener
- aCounterListener
instance.
-
fireIncrementCounter
Inform all registered listeners that the supplied counter needs to be incremented.- Parameters:
event
- aCounterEvent
containing information about the counter to be incremented.
-