com.adventnet.snmp.ui
Class SnmpTasks

java.lang.Object
  |
  +--com.adventnet.snmp.beans.SnmpServer
        |
        +--com.adventnet.snmp.beans.SnmpRequestServer
              |
              +--com.adventnet.snmp.ui.SnmpTasks

class SnmpTasks
extends SnmpRequestServer
implements ResultListener, java.awt.event.ItemListener

See Also:
Serialized Form

Field Summary
(package private)  java.lang.String append_bulk_str
           
(package private)  java.lang.String append_errstr
           
(package private)  java.lang.String append_get_str
           
(package private)  java.lang.String append_next_str
           
(package private)  java.lang.String append_set_str
           
(package private)  java.lang.String append_str
           
(package private)  java.lang.Runnable appendBulkStr
           
(package private)  java.lang.Runnable appendErrStr
           
(package private)  java.lang.Runnable appendGetStr
           
(package private)  java.lang.Runnable appendNextStr
           
(package private)  java.lang.Runnable appendSetStr
           
(package private)  java.lang.Runnable appendStr
           
(package private)  boolean appletexist
           
(package private)  MibBrowser browser
          Implementation of the corresponding ResultListener method
(package private)  java.lang.String community
           
(package private)  java.lang.Runnable expandingTree
           
(package private)  boolean expandTree
           
(package private)  java.lang.String host
           
(package private)  boolean isNumericOid
           
(package private)  java.util.Vector multiOids
          Contains all the OIDs for multi-var request
(package private)  boolean multiVar
           
(package private)  SnmpOID nulloid
           
(package private)  java.lang.String oid
           
(package private)  java.lang.String oidString
           
(package private)  boolean polling
           
(package private)  SnmpOID rootoid
           
(package private) static java.lang.String serStatusFileName
           
(package private)  java.lang.String setval
           
(package private)  java.util.Vector values
          Contains all the Values for multi-var request
(package private)  java.lang.String writeCommunity
           
 
Fields inherited from class com.adventnet.snmp.beans.SnmpRequestServer
destinations, logID, mibModules, prevoid, requests, serialize
 
Fields inherited from class com.adventnet.snmp.beans.SnmpServer
api, applet, ASN1_ERROR_ERR, ASN1_ERROR_OID, attemptCompleteData, attemptPartialData, AUTH_NO_PRIV, AUTH_PRIV, authKey, authPassword, authProtocol, broadCast, clientID, community, contextID, contextName, count, debugon, DECRYPT_ERROR_ERR, DECRYPT_ERROR_OID, discoveryTimeSyncListener, enc, engineID, engineTable, error, errorCode, errorcodes, errorIndex, exceptionCode, exceptionCodes, finalize_called, group, group_oidList, isName, isNotSet, isSendPDUByGroup, listeners, localAddrs, localPort, logFlag, loggerImpl, logLevel, logType, matchServ, matchtable, MAX_NUM_ROWS, maxRepetitions, MD5_AUTH, mibOps, NO_AUTH, NO_AUTH_NO_PRIV, nonRepeaters, NOT_TIME_WINDOWS_ERR, NOT_TIME_WINDOWS_OID, nullsession_targets, oidList, options, pduErrorIndex, pollertargets, pollInterval, port, port_targets, principal, printStr, privKey, privPassword, privProtocol, propertylisteners, protocol, reqHandler, reqid, retries, secModel, securityLevel, sendTimeoutEvents, sentreqid, session, session_port_targets, session_targets, sessionName, SHA_AUTH, SNMPGET, SNMPGETBULK, SNMPGETNEXT, SNMPINFORM, SNMPREPORT, SNMPRESPONSE, SNMPSET, snmpStore, SNMPTRAP, SNMPV2TRAP, targetHost, targets, timeout, UKN_ENGINEID_ERR, UKN_ENGINEID_OID, UKN_USERNAMES_ERR, UKN_USERNAMES_OID, UNSUPP_SEC_LEVEL_ERR, UNSUPP_SEC_LEVEL_OID, userError, userErrorCode, usmTable, v3ErrorTable, validateUser, varbinds_per_request, varList, version, VERSION1, VERSION2C, VERSION3, writeCommunity, WRONG_DIGEST_ERR, WRONG_DIGEST_OID
 
Constructor Summary
(package private) SnmpTasks(MibBrowser browser)
           
(package private) SnmpTasks(MibBrowser browser, java.applet.Applet applet)
           
(package private) SnmpTasks(MibBrowser browser, int protocol, ProtocolOptions opts)
           
 
Method Summary
(package private)  void addVarBindList()
          Adds the OID and Value to the list
(package private)  boolean checkData(java.lang.String val, java.lang.String name)
          check for valid input
(package private)  boolean checkValues()
          check for valid input
protected  void cleanUp()
          This releases the underlying resources.
 void debugPrint(java.lang.String debugOutput)
          This method overrides the SnmpRequestServer that prints to standard error.
(package private)  void editVarBindList()
          Method modifies the OID and Value in the list if edited
(package private)  void get()
          Method used to do GET and WALK operations based on the OID.
(package private)  void getbulk()
          Method used to do GETBULK operation.
(package private)  java.util.Vector getMultipleOids()
          Returns vector of multiple OIDs
(package private)  void getnext()
          Method used to do GETNEXT operation.
(package private)  java.lang.String[] getSetValues()
          Returns array of values to do SET
(package private)  void getValues()
          update all values from the current display
(package private)  boolean isOperationInProgress()
          Returns whether any of the SNMP Operations like GET, GETNEXT, GETBULK,SET are in progress currently.
 void itemStateChanged(java.awt.event.ItemEvent ie)
           
(package private)  void logErrorMessage(java.lang.String error)
          All the methods of this class (including sub classes), which needs to redirect an error message to the LogManger or to the standard console, can use this method.
(package private)  void logInfoMessage(java.lang.String info)
          All the methods of this class (including sub classes), which needs to redirect an info message to the LogManger or to the standard console, can use this method.
(package private)  void removeVarBindList()
          Removes the varbind from the list
(package private)  void set()
          Method used to do SET operation.
 void setMibOperations(MibOperations mibOps)
          Set the MibOperations.This can be used when the API user wants the MibBrowser to use the localinstance of MibOperations instead of the Static MibOperations shared by all the other beans.
 void setNumericResult(long i)
          Implementation of the corresponding ResultListener method
 void setResult(ResultEvent e)
          Implementation of the corresponding ResultListener method
 void setStringResult(java.lang.String s)
          Implementation of the corresponding ResultListener method
(package private)  void stopPoll()
          Reset the polling variable
 
Methods inherited from class com.adventnet.snmp.beans.SnmpRequestServer
addLogClient, addLogClient, addObjectID, addRequest, addResultListener, addSnmpOID, addSnmpPropertyListener, addUserError, addV3HandShakeResultListener, authenticate, callback, deSerializeUSM, genEvent, genTimeoutEvent, getAttemptPartial, getAuthPassword, getAuthProtocol, getCommunity, getContextID, getContextName, getDebug, getEngineID, getErrorCode, getErrorResultString, getErrorString, getMaxRepetitions, getMibModules, getMibOperations, getNonRepeaters, getObjectID, getObjectID, getObjectIDList, getPrincipal, getPrivPassword, getRetries, getSecurityLevel, getSecurityModel, getSendTimeoutEvents, getSnmpOID, getSnmpOIDList, getSnmpVersion, getTargetHost, getTargetPort, getTimeout, getUserErrorCode, getUserErrorString, getWriteCommunity, isBroadCastEnabled, isSerialize, loadMibs, readFromDatabase, releaseResources, removeLogClient, removeResultListener, removeSnmpPropertyListener, removeV3HandShakeListener, sendGetBulkRequestList, sendGetNextRequest, sendGetNextRequest, sendGetNextRequestList, sendGetNextRequestList, sendGetRequest, sendGetRequest, sendGetRequestList, sendGetRequestList, sendSetRequest, sendSetRequest, sendSetRequestList, sendSetRequestVariable, sendSetRequestVariables, sendSNMPRequest, sendTrap, sendTrap, setAttemptPartial, setAuthPassword, setAuthProtocol, setBroadCastEnable, setCommunity, setContextID, setContextName, setDebug, setEngineID, setMaxRepetitions, setMibModules, setNonRepeaters, setObjectID, setObjectID, setObjectIDList, setParams, setParams, setPrincipal, setPrivPassword, setRetries, setSecurityLevel, setSecurityModel, setSendTimeoutEvents, setSnmpOID, setSnmpOIDList, setSnmpVersion, setTargetHost, setTargetPort, setTimeout, setWriteCommunity, updateMibs, vetoableChange
 
Methods inherited from class com.adventnet.snmp.beans.SnmpServer
assignLogger, async_create_v3_tables, create_v3_tables, finalize, genEvent, getCharacterEncoding, getCompleteResponse, getGROUPSNMPResponse, getHostAddress, getIgnoreSpecificControlCodes, getLocalAddresses, getMibPath, getOverwriteCMI, getPacketBufferSize, getPdu, getSecLevelForTimeSync, getSecurityProvider, getSecurityTable, getSerializedMibFileName, getSimpleDateFormat, getSnmpEngineID, getSnmpEngineTable, getSNMPResponse, getSNMPResponse, getSNMPResponse, getTimeoutInMilliSec, getTimeToWait, getUSMTable, getV3ConfigTable, initJdbcParams, initSecurityProvider, initSnmpStore, isBroadcastFeatureEnable, isLoadFromCompiledMibs, isLoadFromSerializedMibs, isLoadMibsFromDatabase, isOverwriteCMI, isOverwriteMibsInDatabase, isReadDesc, isSendPDUByGroup, isSerializeMibs, isSetAutoInformResponse, isSupportedSecurityModel, isV3DatabaseFlag, isValidateUser, manage_v3_tables, managing_v3_tables, sendSNMPRequest, sendSNMPRequest, setAutoInformResponse, setBroadcastFeatureEnable, setCharacterEncoding, setErrorMessage, setIgnoreSpecificControlCodes, setLoadFromCompiledMibs, setLoadFromSerializedMibs, setLoadMibsFromDatabase, setMibPath, setOverwriteCMI, setOverwriteMibsInDatabase, setPacketBufferSize, setPduParams, setReadDesc, setReceiveBufferSize, setSecLevelForTimeSync, setSendPDUByGroup, setSerializedMibFileName, setSerializeMibs, setSimpleDateFormat, setSnmpEngineID, setTimeoutInMilliSec, setTimeToWait, setV3ConfigTable, setV3DatabaseFlag, updateEntry, validateUser
 
Methods inherited from class java.lang.Object
, clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

oidString

java.lang.String oidString

multiVar

boolean multiVar

appletexist

boolean appletexist

expandTree

boolean expandTree

nulloid

SnmpOID nulloid

serStatusFileName

static final java.lang.String serStatusFileName

browser

MibBrowser browser
Implementation of the corresponding ResultListener method

host

java.lang.String host

community

java.lang.String community

writeCommunity

java.lang.String writeCommunity

oid

java.lang.String oid

rootoid

SnmpOID rootoid

setval

java.lang.String setval

append_errstr

java.lang.String append_errstr

appendErrStr

java.lang.Runnable appendErrStr

append_str

java.lang.String append_str

appendStr

java.lang.Runnable appendStr

append_get_str

java.lang.String append_get_str

appendGetStr

java.lang.Runnable appendGetStr

append_next_str

java.lang.String append_next_str

appendNextStr

java.lang.Runnable appendNextStr

append_bulk_str

java.lang.String append_bulk_str

appendBulkStr

java.lang.Runnable appendBulkStr

append_set_str

java.lang.String append_set_str

appendSetStr

java.lang.Runnable appendSetStr

expandingTree

java.lang.Runnable expandingTree

isNumericOid

boolean isNumericOid

polling

boolean polling

multiOids

java.util.Vector multiOids
Contains all the OIDs for multi-var request

values

java.util.Vector values
Contains all the Values for multi-var request
Constructor Detail

SnmpTasks

SnmpTasks(MibBrowser browser)

SnmpTasks

SnmpTasks(MibBrowser browser,
          java.applet.Applet applet)

SnmpTasks

SnmpTasks(MibBrowser browser,
          int protocol,
          ProtocolOptions opts)
Method Detail

getValues

void getValues()
update all values from the current display

get

void get()
Method used to do GET and WALK operations based on the OID.

getnext

void getnext()
Method used to do GETNEXT operation.

getbulk

void getbulk()
Method used to do GETBULK operation.

set

void set()
Method used to do SET operation.

setResult

public void setResult(ResultEvent e)
Implementation of the corresponding ResultListener method
Specified by:
setResult in interface ResultListener

checkValues

boolean checkValues()
check for valid input

checkData

boolean checkData(java.lang.String val,
                  java.lang.String name)
check for valid input

debugPrint

public void debugPrint(java.lang.String debugOutput)
This method overrides the SnmpRequestServer that prints to standard error.
Overrides:
debugPrint in class SnmpRequestServer

setStringResult

public void setStringResult(java.lang.String s)
Implementation of the corresponding ResultListener method
Specified by:
setStringResult in interface ResultListener

setNumericResult

public void setNumericResult(long i)
Implementation of the corresponding ResultListener method
Specified by:
setNumericResult in interface ResultListener

itemStateChanged

public void itemStateChanged(java.awt.event.ItemEvent ie)
Specified by:
itemStateChanged in interface java.awt.event.ItemListener

addVarBindList

void addVarBindList()
Adds the OID and Value to the list

removeVarBindList

void removeVarBindList()
Removes the varbind from the list

editVarBindList

void editVarBindList()
Method modifies the OID and Value in the list if edited

getSetValues

java.lang.String[] getSetValues()
Returns array of values to do SET

getMultipleOids

java.util.Vector getMultipleOids()
Returns vector of multiple OIDs

stopPoll

void stopPoll()
Reset the polling variable

cleanUp

protected void cleanUp()
This releases the underlying resources. Call to this will deregister it as a SnmpRequestListener

setMibOperations

public void setMibOperations(MibOperations mibOps)
Set the MibOperations.This can be used when the API user wants the MibBrowser to use the localinstance of MibOperations instead of the Static MibOperations shared by all the other beans. Note:This will over-write the existing MibOperations used by the other beans.
Overrides:
setMibOperations in class SnmpServer

isOperationInProgress

boolean isOperationInProgress()
Returns whether any of the SNMP Operations like GET, GETNEXT, GETBULK,SET are in progress currently.

logErrorMessage

void logErrorMessage(java.lang.String error)
Description copied from class: SnmpServer
All the methods of this class (including sub classes), which needs to redirect an error message to the LogManger or to the standard console, can use this method. - Mahesh
Overrides:
logErrorMessage in class SnmpServer

logInfoMessage

void logInfoMessage(java.lang.String info)
Description copied from class: SnmpServer
All the methods of this class (including sub classes), which needs to redirect an info message to the LogManger or to the standard console, can use this method. - Mahesh
Overrides:
logInfoMessage in class SnmpServer