HOME

com.ireasoning.protocol.snmp
Interface SnmpBaseGroupMBean

All Superinterfaces:
Serializable
All Known Implementing Classes:
SnmpBaseGroup

public interface SnmpBaseGroupMBean
extends Serializable

This is the MBean interface of SnmpBaseGroup class

See Also:
SnmpBaseGroup

Method Summary
 void postSetValue(SnmpVarBind newValue, Collection varbinds)
          Deprecated, use postSetValue instead
 void postSetValue(SnmpVarBind newValue, SnmpPdu pdu)
          It gets called after agent processes SNMP SET request.
 boolean preSetValue(SnmpVarBind newValue, Collection varbinds)
          Deprecated, use preSetValue instead
 void preSetValue(SnmpVarBind newValue, SnmpPdu pdu)
          It gets called before agent is going to process SNMP SET request.
 

Method Detail

preSetValue

public void preSetValue(SnmpVarBind newValue,
                        SnmpPdu pdu)
It gets called before agent is going to process SNMP SET request.

Because SNMP SET operation is atomic, you may need to override this method in the sub class which accept SET operations. And checks the validity of passed newValue and the pdu object. If value is not acceptable, SnmpException needs to be thrown, so this SET operation fails and proper error status code will be returned to SNMP manager.

Note: SNMP version information of the received packet can be retrieved by calling pdu.getVersion()

Parameters:
newValue - the new value which is being processed
pdu - PDU object received
Throws:
SnmpException - Throw an SnmpException if the passed newValue is not acceptable, and you need to set SnmpException object's errorStatus field, which will be used in the response PDU's errorStatus field.

postSetValue

public void postSetValue(SnmpVarBind newValue,
                         SnmpPdu pdu)
It gets called after agent processes SNMP SET request.

Parameters:
newValue - the new value which is being processed
pdu - PDU object received

preSetValue

public boolean preSetValue(SnmpVarBind newValue,
                           Collection varbinds)
Deprecated, use preSetValue instead


postSetValue

public void postSetValue(SnmpVarBind newValue,
                         Collection varbinds)
Deprecated, use postSetValue instead


HOME

Copyright © 2002 iReasoning Inc. All Rights Reserved.