org.snmp4j.mp
Class CounterSupport

java.lang.Object
  extended by org.snmp4j.mp.CounterSupport

public class CounterSupport
extends java.lang.Object

The CounterSupport class provides support to fire CounterEvent to registered listeners.

Version:
1.0
Author:
Frank Fock

Field Summary
protected static CounterSupport instance
           
 
Constructor Summary
protected CounterSupport()
           
 
Method Summary
 void addCounterListener(CounterListener listener)
          Adds a CounterListener.
 void fireIncrementCounter(CounterEvent event)
          Inform all registered listeners that the supplied counter needs to be incremented.
static CounterSupport getInstance()
          Gets the counter support singleton.
 void removeCounterListener(CounterListener listener)
          Removes a previously added CounterListener.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

instance

protected static CounterSupport instance
Constructor Detail

CounterSupport

protected CounterSupport()
Method Detail

getInstance

public static CounterSupport getInstance()
Gets the counter support singleton.

Returns:
the CounterSupport instance.

addCounterListener

public void addCounterListener(CounterListener listener)
Adds a CounterListener.

Parameters:
listener - a CounterListener instance that needs to be informed when a counter needs to be incremented.

removeCounterListener

public void removeCounterListener(CounterListener listener)
Removes a previously added CounterListener.

Parameters:
listener - a CounterListener instance.

fireIncrementCounter

public void fireIncrementCounter(CounterEvent event)
Inform all registered listeners that the supplied counter needs to be incremented.

Parameters:
event - a CounterEvent containing information about the counter to be incremented.

Copyright 2005-2010 Frank Fock (SNMP4J.org)

Copyright © 2011 SNMP4J.org. All Rights Reserved.