Class SnmpContextv3Pool

java.lang.Object
uk.co.westhawk.snmp.stack.SnmpContextv3Pool
All Implemented Interfaces:
SnmpContextBasisFace, SnmpContextv3Face

public class SnmpContextv3Pool extends Object implements SnmpContextv3Face
This class contains the pool of SNMP v3 contexts. This class reuses the existings contexts instead of creating a new one every time.

Every time a property changes the pool is checked for a SnmpContextv3 context that matches all the new properties of this class. If no such context exists, a new one is made. The PDUs associated with the old context remain associated with the old context.

A counter indicates the number of times the context is referenced. The counter is decreased when destroy() is called. When the counter reaches zero, the context is released.

Note that because the underlying context can change when a property is changed and the PDUs remain associated with the old context, all properties have to be set BEFORE a PDU is sent.

Version:
$Revision: 3.27 $ $Date: 2009/03/05 13:27:41 $
Author:
Birgit Arkesteijn
See Also: