com.adventnet.snmp.snmp2.agent
Class SnmpTargetObjectsRequestHandler

java.lang.Object
  |
  +--com.adventnet.snmp.snmp2.agent.SimpleRequestHandler
        |
        +--com.adventnet.snmp.snmp2.agent.SnmpTargetObjectsRequestHandler

public class SnmpTargetObjectsRequestHandler
extends SimpleRequestHandler

Handles all requests under snmpTargetObjects group


Field Summary
(package private)  SnmpAgent agentName
           
(package private)  SnmpAPI api
           
(package private)  java.util.Hashtable atomicTable
           
protected  java.lang.Integer snmpTargetSpinLock
          The SpinLock Integer.
(package private) static int SNMPTARGETSPINLOCK
           
(package private) static int SNMPUNAVAILABLECONTEXTS
           
(package private) static int SNMPUNKNOWNCONTEXTS
           
 
Fields inherited from class com.adventnet.snmp.snmp2.agent.SimpleRequestHandler
instrumentHandler, listener, tableListener, writeEachTime
 
Constructor Summary
SnmpTargetObjectsRequestHandler(SnmpAgent agentRef)
          Default constructor that takes the SnmpAgent as the argument.
 
Method Summary
 int[] getOidRep()
          Retrives the integer representation of OID
static int[] getSnmpTargetObjectsOidRep()
          Gets the SnmpTargetObjects group int[] rep {1,3,6,1,6,3,12,1}
 java.lang.Integer getSnmpTargetSpinLock()
          Getter for the Snmp Target Spin Lock value
protected  int[] getSubidList()
          Gets the subid list of the oid.
protected  void processGetNextRequest(SnmpVarBind varb, AgentNode node, VarBindRequestEvent pe)
          Process the GetNext Request message which is received from PduRequestHandler.
protected  void processGetRequest(SnmpVarBind varb, AgentNode node, VarBindRequestEvent pe)
          Process the Get Request message which is received from PduRequestHandler.
protected  void processSetRequest(SnmpVarBind varb, AgentNode node, VarBindRequestEvent pe)
          Process the Set Request message which is received from PduRequestHandler.
 void setSnmpTargetSpinLock(SnmpVar var)
          Setter for the Snmp Target Spin Lock value
 
Methods inherited from class com.adventnet.snmp.snmp2.agent.SimpleRequestHandler
addInstrumentHandler, addRegistrationListener, addTableListener, addUpdateListener, getInstrument, getMibVarHash, getNextRequest, getObjectHash, getObjectTypeHash, getRequest, getTableListener, isWriteEachTime, processGetNextRequest, processGetRequest, processSetRequest, removeRegistrationListener, removeUpdateListener, setRequest, setWriteEachTime, writeIntoFile
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SNMPTARGETSPINLOCK

static final int SNMPTARGETSPINLOCK

SNMPUNAVAILABLECONTEXTS

static final int SNMPUNAVAILABLECONTEXTS

SNMPUNKNOWNCONTEXTS

static final int SNMPUNKNOWNCONTEXTS

agentName

SnmpAgent agentName

api

SnmpAPI api

snmpTargetSpinLock

protected java.lang.Integer snmpTargetSpinLock
The SpinLock Integer.

atomicTable

java.util.Hashtable atomicTable
Constructor Detail

SnmpTargetObjectsRequestHandler

public SnmpTargetObjectsRequestHandler(SnmpAgent agentRef)
Default constructor that takes the SnmpAgent as the argument.
Parameters:
agentRef - instance of SnmpAgent
Method Detail

getSnmpTargetObjectsOidRep

public static int[] getSnmpTargetObjectsOidRep()
Gets the SnmpTargetObjects group int[] rep {1,3,6,1,6,3,12,1}
Returns:
The registered OID as an int array

getOidRep

public int[] getOidRep()
Description copied from class: SimpleRequestHandler
Retrives the integer representation of OID
Overrides:
getOidRep in class SimpleRequestHandler
Tags copied from class: SimpleRequestHandler
Returns:
the integer array of OID

getSubidList

protected int[] getSubidList()
Description copied from class: SimpleRequestHandler
Gets the subid list of the oid.
Overrides:
getSubidList in class SimpleRequestHandler
Tags copied from class: SimpleRequestHandler
Returns:
the integer array of subid list

processGetRequest

protected void processGetRequest(SnmpVarBind varb,
                                 AgentNode node,
                                 VarBindRequestEvent pe)
                          throws AgentSnmpException
Description copied from class: SimpleRequestHandler
Process the Get Request message which is received from PduRequestHandler.
Overrides:
processGetRequest in class SimpleRequestHandler
Tags copied from class: SimpleRequestHandler
Parameters:
varb - The received varbind .
node - The node for which Get Request is to be done.
pe - The VarBind Request Event created by this Get request.
Throws:
AgentSnmpException - This wraps all the Exceptions thrown while Processing the Event.

processSetRequest

protected void processSetRequest(SnmpVarBind varb,
                                 AgentNode node,
                                 VarBindRequestEvent pe)
                          throws AgentSnmpException
Description copied from class: SimpleRequestHandler
Process the Set Request message which is received from PduRequestHandler.
Overrides:
processSetRequest in class SimpleRequestHandler
Tags copied from class: SimpleRequestHandler
Parameters:
varb - The received varbind.
node - The node for which Get Next Request is to be done.
pe - The VarBind Request Event created by this GetNext request.
Throws:
AgentSnmpException - This wraps all the Exceptions thrown while Processing the Event.

processGetNextRequest

protected void processGetNextRequest(SnmpVarBind varb,
                                     AgentNode node,
                                     VarBindRequestEvent pe)
                              throws AgentSnmpException
Description copied from class: SimpleRequestHandler
Process the GetNext Request message which is received from PduRequestHandler.
Overrides:
processGetNextRequest in class SimpleRequestHandler
Tags copied from class: SimpleRequestHandler
Parameters:
varb - The received varbind.
node - The node for which Get Next Request is to be done.
pe - The VarBind Request Event created by this GetNext request.
Throws:
AgentSnmpException - This wraps all the Exceptions thrown while Processing the Event.

getSnmpTargetSpinLock

public java.lang.Integer getSnmpTargetSpinLock()
                                        throws AgentException
Getter for the Snmp Target Spin Lock value
Returns:
The SpinLock Integer of this group.
Throws:
AgentException - This wraps all the exceptions thrown during this event.

setSnmpTargetSpinLock

public void setSnmpTargetSpinLock(SnmpVar var)
                           throws AgentSnmpException,
                                  AgentException
Setter for the Snmp Target Spin Lock value
Parameters:
var - specifies the SnmpVar object for SnmpTargetSpinLock
Throws:
AgentSnmpException, - AgentException This wraps all the exceptions thrown during this event.