com.tivoli.twg.snmp
Class SNMPContext

java.lang.Object
  extended bycom.tivoli.twg.snmp.SNMPContext

public class SNMPContext
extends java.lang.Object

This class represents an SNMP Context. In version 1.x, that is a community name. In version 2.x that is a party.

It is required for all protocol operations. One is required to transmit a PDU, and one will be provided on the arrival of both a response, and a Trap PDU.

See Also:
SNMP, SNMPEntity, SNMPPDU

Constructor Summary
SNMPContext(SNMP session, java.lang.String address)
          Deprecated.  
SNMPContext(java.lang.String address)
          Construct An SNMPContext for use with all protocol operations
 
Method Summary
 java.lang.String GetContext()
          This method will return the original Community, or party name for this Context instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SNMPContext

public SNMPContext(java.lang.String address)
Construct An SNMPContext for use with all protocol operations

Parameters:
address - A string representing either a V1 community name, or a V2 party name.

SNMPContext

public SNMPContext(SNMP session,
                   java.lang.String address)
Deprecated.  

Construct An SNMPContext for use with all protocol operations

Parameters:
session - An instance of the SNMP class, ie, the protocol stack
address - A string representing either a V1 community name, or a V2 party name.
Method Detail

GetContext

public final java.lang.String GetContext()
This method will return the original Community, or party name for this Context instance.

Returns:
the string that was used to construct this Context instance.