|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
| Method Summary | |
void |
addAccessId(java.lang.String commandCode,
java.lang.String accessId)
Adds an accessId for a Command Code. |
void |
addAccessId(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId)
Adds an accessId for a Command Code. |
void |
addLines(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to an autonomous code and alarm description combination. |
void |
addLines(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. |
void |
addLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to an autonomous code and alarm description combination. |
void |
addLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. |
boolean |
addMibFileToDevice(java.lang.String ipAddress,
int port,
java.lang.String mibFile)
This method is used to add a MIB file to an already existing SNMP device.It is mandatory that the SNMP agent should exists in the network. |
void |
addMsgPayLoad(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Adds a new Message PayLoad. |
void |
addMsgPayLoad(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Adds a new Message PayLoad. |
void |
addParameters(java.lang.String paramKey,
java.lang.String paramValue)
This Method adds the paramvalue argument for the given paramkey in the base table Note : When the key specified is already present , new value will be updated for the key -Applicable Only in IOS Devices. |
boolean |
addSnmpAgent(java.lang.String devName,
java.lang.String ipAddress,
java.lang.String port,
java.lang.String readCommunity,
java.lang.String writeCommunity,
java.lang.String tftpPort)
This method is used to add an SNMP agent to an already existing network. |
boolean |
changeDirectory(java.lang.String dir)
This method gives the current working directory. |
void |
changeMode(int mode)
This Method changes the Mode to the specified level.(However from user mode you can move only to enable mode , which will ask for a password and not all those above it) -Applicable Only in IOS Devices. |
void |
clearAllAutonomousMessages()
Clears all the autonomous messages that were sent previously from all the TL1 agents in the selected network |
void |
clearAutonomousMessagesInDevice(java.lang.String ipAddress,
java.lang.String port)
Clears all the autonomous messages that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable. |
void |
deleteAccessId(java.lang.String commandCode,
java.lang.String accessId)
Deletes an accessId for a Command Code. |
void |
deleteAccessId(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId)
Deletes an accessId for a Command Code. |
void |
deleteAllRows(java.lang.String tableEntryOid)
Deletes all the rows in the table |
void |
deleteAllRows(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
Deletes all rows in the table |
void |
deleteLine(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. |
void |
deleteLine(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. |
void |
deleteLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. |
void |
deleteLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. |
void |
deleteParameters(java.lang.String paramKey)
This method deletes the paramKey entry along with the paramValue in the base table -Applicable Only in IOS Devices. |
void |
deleteRow(java.lang.String tableEntryOid,
java.lang.String instance)
Deletes a row with the specified instance from the table |
void |
deleteRow(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid,
java.lang.String instance)
Deletes a row with the specified instance from the table |
void |
deleteRowWithValue(java.lang.String tableEntryOid,
java.lang.String columnName,
java.lang.String value)
Deletes the specified row in the table which will match with the column value specified |
void |
deleteRowWithValue(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tableEntryOid,
java.lang.String columnName,
java.lang.String value)
Deletes the specified row in the table which will match with the column value specified in the specified device. |
boolean |
deleteSnmpAgent(java.lang.String ipAddress,
java.lang.String port)
This method is used to delete the SNMP agent with IP Address and Port from the currently selected network in the Network Desginer. |
void |
delLines(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) for a autonomouse code and alarm description combination. |
void |
delLines(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean responseType,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. |
void |
delLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) for a autonomouse code and alarm description combination. |
void |
delLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean responseType,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. |
void |
delMsgPayLoad(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Deletes a Message PayLoad. |
void |
delMsgPayLoad(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Deletes a Message PayLoad. |
boolean |
downInterface(java.lang.String ifIndex)
This method is used to shutdown the given interface of the SNMP Agent.The interface will be shutdown only when the SNMP Agent is running. |
boolean |
downInterface(java.lang.String ipAddress,
int port,
java.lang.String ifIndex)
This method is used to shutdown the interface for an SNMP agent with IP Address and Port from the currently selected network in the Network Desginer.The interface will be shutdown only when the agent is running. |
boolean |
downloadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol)
The method will download the file from source to target in binary or ascii mode. |
boolean |
downloadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol,
java.lang.String userName,
java.lang.String password)
The method will download from source to target in binary or ascii mode. |
java.lang.String |
execDisplayCommand(java.lang.String cmd)
This method can be used for commands which result in some output display.The output should be specific to the directory from which it is being executed. |
void |
execGlobalTelnetCmd(java.lang.String cmd)
This method shall be used for commands that result in some action being executed in the system without any output display.The action should be executed globally. |
java.lang.String |
executeGlobalCmd(java.lang.String cmd)
This method can be used for commands which result in some output display.The output should be irrespective to the directory from which it is being executed. |
java.lang.String |
executeScript(java.lang.String scriptFile)
This method gives the response of a script and helps in executing a script within a script -Applicable Only in IOS Devices. |
void |
executeTelnetCmd(java.lang.String cmd)
This method shall be used for commands that result in some action being executed in the system without any output display.The action executed should be within the specified directory. |
java.util.Vector |
getAllAids(java.lang.String commandCode)
Gets all the Access Identifiers configured for a command code. |
java.util.Vector |
getAllAids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode)
Gets all the Access Identifiers configured for a command code. |
java.lang.String[] |
getAllColumnByNames(java.lang.String tableEntryOid)
This method will return all the columnar node names of a particular table, in a String array |
java.lang.String[] |
getAllColumnByNames(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
This method will return all the columnar node names of a particular table, in a String array |
java.lang.String[] |
getAllColumnByOids(java.lang.String tableEntryOid)
This method will return all the columnar node OIDs of a particular table, in a String array |
java.lang.String[] |
getAllColumnByOids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
This method will return all the columnar node OIDs of a particular table, in a String array |
java.util.ArrayList |
getAllDeviceNames()
This method is used to list all the names of the devices present in the Device Tree. |
java.lang.String[] |
getAllIndices(java.lang.String tableEntryOid)
This method will return all the index column name of a particular table, in a String array |
java.lang.String[] |
getAllIndices(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
This method will return all the index column name of a particular table, in a String array |
java.util.Vector |
getAllMpbs(java.lang.String commandCode,
java.lang.String accessID)
Gets all the Message Payload configured for a command code and access identifier combination. |
java.util.Vector |
getAllMpbs(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Gets all the Message Payload configured for a command code and access identifier combination. |
java.util.Hashtable |
getAllTableValues(java.lang.String tableEntryOid)
Get all the table values in the table. |
java.util.Hashtable |
getAllTableValues(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
Get all the table values in the table. |
java.util.Vector |
getAutonomousDetails()
Gets all the autonomous messages details that were sent previously from all the TL1 agents in the selected network |
java.util.Vector |
getAutonomousDetailsForDevice(java.lang.String ipAddress,
java.lang.String port)
Gets all the autonomous messages details that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable. |
java.lang.String |
getCmdWord(int index)
This Method gives the part of the Command for the given index -Applicable Only in IOS Devices. |
java.lang.String |
getConfigDirectory()
Gets the current working directory i.e. |
java.lang.String |
getCurrentAID()
Gets the accessId that comes in the request. |
int |
getCurrentColumn()
> Gets the current column i.e. |
java.lang.String |
getCurrentCommand()
This Method will give the current Command which is being executed -Applicable Only in IOS Devices. |
java.lang.String |
getCurrentCommandCode()
Gets the Command code that comes in the request. |
java.lang.String |
getCurrentInstance()
Gets the current instance i.e. |
int |
getCurrentLevel()
This Method gives the level at which the command is executed -Applicable Only in IOS Devices. |
java.lang.String |
getCurrentMPB()
Gets the msgPayLoad that comes in the request. |
java.lang.String |
getCurrentOID()
Gets the current OID |
java.lang.String |
getCurrentOIDWithInstance()
Gets the current OID with the instance appended to it. |
java.lang.String |
getCurrentValue()
Gets the current value i.e. |
java.lang.String |
getDeviceName()
This method gets the device name for which the request has come. |
boolean |
getEnableFlag()
This method returns whether the enable password is set or not in the device. |
java.lang.String |
getEnablePassword()
This method gets the password for the enable mode for which the request has come - Applicable Only in IOS Devices |
java.lang.String |
getErrIndex()
Gets the errIndex of the response to the Inform Request |
java.lang.String |
getErrStat()
Gets the errStat value of the response to the Inform Request |
java.lang.String |
getHighestIPAddress(java.util.Vector ipAddr)
This method returns the highest IPAddress present in the given Vector. |
java.util.Vector |
getInstances(java.lang.String tableOid)
Gets all the instances in a table |
java.util.Vector |
getInstances(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid)
Gets all the instances in a table |
java.lang.String |
getInterfaceStatus()
This Method gives what interface is being configured -Applicable Only in IOS Devices. |
java.lang.String |
getIPAddress()
Gets the IP Address of the agent for which the request has come |
java.util.Hashtable |
getLine(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. |
java.util.Hashtable |
getLine(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. |
java.util.Hashtable |
getLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. |
java.util.Hashtable |
getLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. |
int |
getMaxRoundTripTime()
This method gives the maximum time taken by isInterfaceUp method to check whether a particular IPAddress is up or not and hence has to be called after isInterfaceUp method |
int |
getMinRoundTripTime()
This method gives the minimum time taken by isInterfaceUp method to check whether a particular IPAddress is up or not and hence has to be called after isInterfaceUp method |
java.lang.String |
getMode()
This Method gives the Current mode at which the commands are executed -Applicable Only in IOS Devices. |
java.lang.String |
getNetworkAddress(java.lang.String ipAddress)
This method returns the Network Address for th given IPAddress. |
java.lang.String |
getNextInstance(java.lang.String tableOid,
java.lang.String instance)
Gets the instance next to the specified instance |
java.lang.String |
getNextInstance(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid,
java.lang.String instance)
Gets the instance next to the specified instance |
java.lang.String |
getNodeValue(java.lang.String objectId,
java.lang.String instance)
Gets the current value of a MIB node |
java.lang.String |
getNodeValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance)
Gets the current value of a MIB node |
int |
getNoOfSnmpAgentsRunning()
This method is used to return the number of Snmp Agents running |
int |
getNumberOfAids(java.lang.String commandCode)
Gets the number of Access Identifiers configured for a command code. |
int |
getNumberOfAids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode)
Gets the number of Access Identifiers configured for a command code. |
int |
getNumberOfMpbs(java.lang.String commandCode,
java.lang.String accessID)
Gets the number of Message PayLoad configured for a command code and access identifier combination. |
int |
getNumberOfMpbs(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Gets the number of Message PayLoad configured for a command code and access identifier combination. |
java.util.Vector |
getParamKeyList(java.lang.String paramKey)
This method will return all the paramKeys in the base table which start with the argument -Applicable Only in IOS Devices. |
java.util.Vector |
getParamListValues(java.lang.String paramKey)
This function returns the paramValue for all the paramKeys (Which are the part of the argument ) -Applicable Only in IOS Devices. |
java.lang.String |
getParamValue(java.lang.String paramKey)
This method returns the paramValue for the paramkey -Applicable Only in IOS Devices. |
java.lang.String |
getPassword()
This method gets the password for the device for which the request has come |
int |
getRequestType()
Gets the request type * |
int |
getRoundTripTime()
This method gives the average time taken by isInterfaceUp method to check whether a particular IPAddress is up or not and hence has to be called after isInterfaceUp method |
int |
getRowCount(java.lang.String tableOid)
Gets the total number of rows in a table.If the agent is not running it returns -1. |
int |
getRowCount(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid)
Gets the total number of rows in a table |
int |
getScriptConditionForSnmpAgent()
Gets the condition for the script in execution. |
int |
getScriptConditionForTL1Agent()
Gets the condition for the script in execution. |
java.lang.String |
getScriptFile(java.lang.String command,
java.lang.String modeis)
This method returns the ScriptFile for the given Command -Applicable Only in IOS Devices. |
java.lang.String |
getSnmpIPAddress()
Gets the IP Address of the agent for which the request has come |
java.lang.String |
getSnmpOidForNodeName(java.lang.String nodeName)
This method will return the SNMP OID for the node name |
java.lang.String |
getSnmpOidForNodeName(java.lang.String ipAddress,
int port,
java.lang.String nodeName)
This method will return the SNMP OID for the node name |
int |
getSnmpPort()
Gets the port at which the agent is running |
java.lang.String |
getTelnetCommands(int dev)
This method returns all the commands supported by the device. |
java.lang.String |
getTelnetRootDir()
This method returns the working directory of the device for which the request has come. |
java.lang.String |
getTL1ConfigDirectory()
Gets the current working directory i.e. |
java.lang.String |
getTL1IPAddress()
Gets the current IPAddress of the agent being queried. |
int |
getTL1Port()
Gets the current port of the agent being queried. |
int |
getTotalColumns(java.lang.String tableEntryOid)
This method will return the total number of columns of a particular table.If the oid specified is not a table Entry Oid , -1 will be returned. |
int |
getTotalColumns(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
This method will return the total number of columns of a particular table.If the oid specified is not a table Entry Oid , -1 will be returned. |
java.lang.String |
getUserName()
This method gets the user name for the device. |
void |
insertRow(java.lang.String tableOid,
java.lang.String[] objectId,
java.lang.String[] values,
java.lang.String[] simTypes)
Inserts a row in a table |
void |
insertRow(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid,
java.lang.String[] objectId,
java.lang.String[] values,
java.lang.String[] simTypes)
Inserts a row in a table |
boolean |
isAidExists(java.lang.String commandCode,
java.lang.String accessID)
Checks if the given access identifier already exists for the command code. |
boolean |
isAidExists(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Checks if the given access identifier already exists for the command code. |
boolean |
isInterfaceUp(java.lang.String ipAddress)
This method checks whether a particular IPAddress is up or not |
boolean |
isMpbExists(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad)
Checks if the given message payload already exists for the command code and access identifer combination. |
boolean |
isMpbExists(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad)
Checks if the given message payload already exists for the command code and access identifer combination. |
boolean |
isSnmpAgentRunning(java.lang.String ipAddress,
java.lang.String port)
This method returns true if the SNMP Agent is running at the specified IP Address and Port , and returns false if the SNMP Agent is not running. |
boolean |
isTftpRunning(java.lang.String ipAddress,
int port)
The method to check if the TFTP server is running at the specified host and port |
void |
maskNode(java.lang.String objectId,
java.lang.String instance,
java.lang.String maskValue)
Masks a node from the manager |
void |
maskNode(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String maskValue)
Masks a node from the manager |
boolean |
modifyTimerScriptParameters(java.lang.String ipAddress,
int port,
java.lang.String scriptFile,
java.lang.String date,
long timerInterval,
int noOfTimes)
This method is used to modify timer parameters for Timer Scripts in the SNMP agent with IP Address and Port from the currently selected network in the Network Desginer. |
boolean |
modifyTimerScriptParameters(java.lang.String scriptFile,
java.lang.String date,
long timerInterval,
int noOfTimes)
This method is used to modify timer parameters for Timer Scripts in the SNMP agent with IP Address and Port from the currently selected network in the Network Desginer. |
void |
noEnablePassword()
This method sets the enable flag to be false and disables the enable password field For e.g scriptinterface.noEnablePassword() |
void |
sendAutonomousMessage(java.lang.String autoCode,
java.lang.String almDescr)
Sends a single autonomous message for the given autoCode and almDescr. |
void |
sendAutonomousMessage(java.lang.String autoCode,
java.lang.String almDescr,
int numberOfTimes,
int interval)
Sends autonomous message a specified number of times with specified time interval . |
void |
sendAutonomousMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String almDescr)
Sends a single autonomous message for the given autoCode and almDescr. |
void |
sendAutonomousMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String almDescr,
int numberOfTimes,
int interval)
Sends autonomous message a specified number of times with specified time interval. |
void |
sendAutonomousMessages()
Sends all the autonomous messages that were sent previously from all the TL1 agents in the selected network |
void |
sendAutonomousMessagesInDevice(java.lang.String ipAddress,
java.lang.String port)
Sends all the autonomous messages that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable. |
void |
sendDenyMessage(java.lang.String errorCode,
java.lang.String explanation)
Sends a deny message with the provided errorCode and explanation |
void |
sendInform(java.lang.String mgrName,
java.lang.String mgrPort,
java.lang.String community,
java.lang.String sysUpTime,
java.lang.String snmpTrapOid)
Sends an inform request without varbinds |
void |
sendInform(java.lang.String mgrName,
java.lang.String mgrPort,
java.lang.String community,
java.lang.String sysUpTime,
java.lang.String snmpTrapOid,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends an inform request with varbinds |
void |
sendResponseMessage(java.lang.String[] paramNames,
java.lang.String[] paramPosType,
java.lang.String[] delimiters,
java.util.Vector paramValuesVector,
java.lang.String[] lineTypes,
int completionCode)
Sends a Response Message with the parameters defined inside the script |
void |
sendTrap(java.lang.String associatedVariable)
This method will send the trap corresponding to the associated variable specified |
void |
sendTrap(java.lang.String trapName,
java.lang.String enterpriseOID)
This method will send the trap corresponding to the associated variable with enterpriseOID specified. |
void |
sendTrap(java.lang.String associatedVariable,
java.lang.String ipAddress,
java.lang.String snmpPort)
|
void |
sendV1Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType)
Sends a V1 Trap with no varbinds |
void |
sendV1Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a V1 Trap with varbinds |
void |
sendV1Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType)
Sends a V1 Trap with no varbinds |
void |
sendV1Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a V1 Trap with varbinds |
void |
sendV2Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String informOID)
Sends a v2 Inform without any extra varbinds |
void |
sendV2Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v2 Inform with extra varbinds |
void |
sendV2Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String informOID)
Sends a v2 Inform without any extra varbinds |
void |
sendV2Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v2 Inform with extra varbinds |
void |
sendV2Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID)
Sends a v2 Trap without any extra varbinds |
void |
sendV2Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v2 Trap with extra varbinds |
void |
sendV2Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID)
Sends a v2 Trap without any extra varbinds |
void |
sendV2Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v2 Trap with extra varbinds |
void |
sendV3Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
Sends a v3 Inform without varbinds |
void |
sendV3Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v3 Inform with varbinds |
void |
sendV3Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
Sends a v3 Inform without varbinds |
void |
sendV3Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v3 Trap with varbinds |
void |
sendV3Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
Sends a v3 Trap without varbinds |
void |
sendV3Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v3 Trap with varbinds |
void |
sendV3Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
Sends a v3 Trap without varbinds |
void |
sendV3Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
Sends a v3 Trap with varbinds |
void |
setAckMessage(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int ackNO)
Sets the Acknowledgement Message for a commandCode, accessId, msgPayLoad combination. |
void |
setAckMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int ackNO)
Sets the Acknowledgement Message for a commandCode, accessId, msgPayLoad combination. |
void |
setComplCode(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int complCode)
Sets the Completion Code(COMPLD,DENY) for a commandCode, accessId, msgPayLoad combination. |
void |
setComplCode(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int complCode)
Sets the Completion Code(COMPLD,DENY) for a commandCode, accessId, msgPayLoad combination. |
void |
setConnectionTime(int time)
This sets the session time of the telnet client.sessiontime : The time till which the client connection should be established while client is idle -Applicable Only in IOS Devices. |
void |
setEnablePassword(java.lang.String password)
This method sets the Enable mode password for the device for which the request has come - Applicable Only in IOS Devices |
void |
setPassword(java.lang.String password)
This method sets the password for the device for which the request has come |
void |
setSnmpCharacterEncoding(java.lang.String encode)
Sets the character encoding |
void |
showHistory()
This function lists the last 10 commands executed by the telnet client -Applicable Only in IOS Devices. |
boolean |
startAgent(java.lang.String uniqueName)
Describe registerToRMI method here. |
boolean |
startAgent(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tl1Port)
This method is used to start a Snmp/Tl1 agent using the ipAddress and Port given. |
boolean |
startTftpServer(java.lang.String ipAddress,
java.lang.String port,
java.lang.String rootDir)
This method will start the TFTP server at the specified host and port number with the root directory |
boolean |
stopAgent(java.lang.String uniqueName)
|
boolean |
stopAgent(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tl1Port)
This method is used to stop a Snmp/Tl1 agent using the ipAddress and Port given. |
boolean |
stopAllTimerInforms()
This method is used to stop Timer Informs for all SNMP agents from the currently selected network in the Network Desginer. |
boolean |
stopAllTimerScripts()
This method is used to stop Timer Scripts for all SNMP agents from the currently selected network in the Network Desginer. |
boolean |
stopAllTimerTraps()
This method is used to stop Timer Traps for all SNMP agents from the currently selected network in the Network Desginer. |
boolean |
stopTftpServer(java.lang.String ipAddress,
java.lang.String port)
This method will stop the TFTP server running at the specified host and port number |
boolean |
stopTimerScripts(java.lang.String ipAddress,
java.lang.String port)
This method is used to stop Timer Scripts for the SNMP agent with IP Address and Port from the currently selected network in the Network Desginer. |
boolean |
stopTimerTraps(java.lang.String ipAddress,
java.lang.String port)
This method is used to stop Timer Traps for the SNMP agent with IP Address and Port from the currently selected network in the Network Desginer. |
void |
strAppend(java.lang.String response)
This method can be used to append any string as a response to be recieved for a command.This should be used only when the command is going to display an output without performing any other operation.To explain in brief, this method shall be used for displaying Inforamation and not for setting any configuration. |
void |
terminateOperation(int errorNumber)
Terminates the current operation i.e. |
void |
updateHost(java.lang.String name)
This Method updates the host name with the given Name -Applicable Only in IOS Devices. |
void |
updateIPAddress(java.lang.String ipAddress)
This method is used to update the IPAddress of the device -Applicable Only in IOS Devices |
void |
updateNodeValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String value)
Updates the value of mib node |
void |
updateParamValue(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. |
void |
updateParamValue(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. |
void |
updateParamValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. |
void |
updateParamValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. |
void |
updateScriptFile(java.lang.String command,
java.lang.String scriptFile,
java.lang.String modeis)
This method uploads the new ScriptFile for the given command -Applicable Only in IOS Devices. |
void |
updateValue(java.lang.String objectId,
java.lang.String instance,
java.lang.String value)
Updates the value of a scalar or a columnar node The node being updated here will be assigned a simulation type of CONST |
void |
updateValue(java.lang.String objectId,
java.lang.String instance,
java.lang.String value,
java.lang.String simType)
Update the value of a scalar or a columnar node with a particular simulation type |
void |
updateValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String value,
java.lang.String simType)
Updates the simtype & value of mib node |
boolean |
upInterface(java.lang.String ifIndex)
This method is used to activate the given interface of the SNMP Agent.The interface will be activated only when the SNMP Agent is running. |
boolean |
upInterface(java.lang.String ipAddress,
int port,
java.lang.String ifIndex)
This method is used to activate the interface IPAddress for an SNMP agent with IP Address and Port from the currently selected network in the Network Desginer.The interface will be activated only when the SNMP agent is running. |
boolean |
uploadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol)
The method will execute the command from source to target in binary or ascii mode. |
boolean |
uploadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol,
java.lang.String userName,
java.lang.String password)
The method will execute the command from source to target in binary or ascii mode. |
| Method Detail |
public void updateValue(java.lang.String objectId,
java.lang.String instance,
java.lang.String value)
Updates the value of a scalar or a columnar node The node being updated here will be assigned a simulation type of CONST
objectId - is the object identifier (without the instance)
of the mib node whose value has to be updatedinstance - is the instance of the node for which the
value should be updated, for scalar nodes this should be ".0"value - is the value to be assigned to the node
For e.g.
To update the value of the variable ' ifAdminStatus ' to
3 enter the following line in the script file
scriptinterface.updateValue(".1.3.6.1.2.1.2.2.1.7",".1","3")
where .1.3.6.1.2.1.2.2.1.7.1 is the object identifier of the node
ifAdminStatus with instance .1 and 3 is the value to be updated
public void updateValue(java.lang.String objectId,
java.lang.String instance,
java.lang.String value,
java.lang.String simType)
objectId - is the object identifier (without the instance) of
the mib node whose value has to be updatedinstance - is the instance of the node for which the
value should be updated, for scalar nodes this should be ".0"value - is the value to be assigned to the node. value should be
given according to the simulation typesimType - is the type of simulation required. This should be
one of the following
CONST - This would constantly respond with the given value
RANDOM - value should be in the format startingRange..endingRange (dots are included)
EXPONENTIAL - value should in the format "a|b" for the equation [y = a * e ^ ( b * x )]
WAVE - The wave type is generated using the formula [y = a * cos ( w * t ) ] the required
input values are a and w
LINEAR - The Linear type is generated using the formula [y = m * x + c ]
the required input values being m and c
SIN WAVE : The sine wave would generate using the formula [a * sin ( w * t )]
the required input values would be a and w
For e.g.
scriptinterface.updateValue(".1.3.6.1.2.1.11.2",".0","400..500","RANDOM")
scriptinterface.updateValue(".1.3.6.1.2.1.11.3",".0","100|32","WAVE")
scriptinterface.updateValue(".1.3.6.1.2.1.11.4",".0","100|80","LINEAR")
scriptinterface.updateValue(".1.3.6.1.2.1.11.5",".0","400|30","SIN_WAVE")
public void insertRow(java.lang.String tableOid,
java.lang.String[] objectId,
java.lang.String[] values,
java.lang.String[] simTypes)
tableOid - - the object identifier of the table in
which the row has to be addedobjectId - - A string array of object identifiers (object id of the
columns in the table)values - - A string array of values for the above given columnssimTypes - - A string array of simulation types for the above columns.
This should be one of the following
The objectId array should contain the object id of only those columns for which the user is interested in specifying a value. The rest of the columns in the table will be assigned default simulated values. Please note that the index columns are an exception and values for all the index columns have to be given
For e.g.
if an entry has to be added in the 'ifTable' but all the columns
can be assigned default values then
objectid = array([".1.3.6.1.2.1.2.2.1.1"],String)
simtypes = array(["CONST"],String)
values = array(["3"],String)
scriptinterface.insertRow(".1.3.6.1.2.1.2.2",objectid,values,simtypes)
This will insert a row in the ifTable with the instance as ".3"
and default values for all the columns
public void deleteRow(java.lang.String tableEntryOid,
java.lang.String instance)
tableEntryOid - is the Object Id of the table entry nodeinstance - is the instance of the entry to be deleted
For e.g. To delete the entry with instance ".1" from the ifTable
specify the following line in the script file
scriptinterface.deleteRow(".1.3.6.1.2.1.2.2.1",".1")
where .1.3.6.1.2.1.2.2.1 is the object id of the ifEntry node and
".1" is the instance to be deleted
public void deleteAllRows(java.lang.String tableEntryOid)
tableEntryOid - is the Object Id of the table entry node
For e.g.
To delete all the entries in the 'ifTable' specify the
following line in the script file
scriptinterface.deleteAllRows(".1.3.6.1.2.1.2.2.1")
where .1.3.6.1.2.1.2.2.1 is the object id of the ifEntry node
public void deleteRowWithValue(java.lang.String tableEntryOid,
java.lang.String columnName,
java.lang.String value)
tableEntryOid - is the Object Id of the table entry nodecolumnName - is the name of the column in the tablevalue - is the value to be mathched with the value present in the column.
For e.g.
To delete the entry in the 'ifTable' having value 'descr' for the ifDescr column specify the
following line in the script file
scriptinterface.deleteRowWithValue(".1.3.6.1.2.1.2.2.1","ifDescr","descr")
where .1.3.6.1.2.1.2.2.1 is the object id of the ifEntry node
public void deleteRowWithValue(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tableEntryOid,
java.lang.String columnName,
java.lang.String value)
ipAddress - is the ipAddress of the devicesnmpPort - is the snmp porttableEntryOid - is the Object Id of the table entry nodecolumnName - is the name of the column in the tablevalue - is the value to be mathched with the value present in the column.
For e.g.
To delete the entry in the 'ifTable' having value 'descr' for the ifDescr column specify the
following line in the script file
scriptinterface.deleteRowWithValue("21.1.1.1","8001",".1.3.6.1.2.1.2.2.1","ifDescr","descr")
where .1.3.6.1.2.1.2.2.1 is the object id of the ifEntry node
public java.util.Hashtable getAllTableValues(java.lang.String tableEntryOid)
tableEntryOid - is the Object Id of the table Entry node
For e.g.
To get all the values in the table specify the following details in the script file
scriptinterface.getAllTableValues(".1.3.6.1.2.1.2.2.1")
where .1.3.6.1.2.1.2.2.1 is the table entry oid of the ifTable ( oid of ifEntry node )
public java.util.Hashtable getAllTableValues(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
tableEntryOid - is the Object Id of the table Entry nodeipAddress - is the ipAddress of the deviceport - - the port at which the agent is running
For e.g.
To get all the values in the table specify the following details in the script file
scriptinterface.getAllTableValues("192.168.1.129","8002",".1.3.6.1.2.1.2.2.1")
where .1.3.6.1.2.1.2.2.1 is the table entry oid of the ifTable ( oid of ifEntry node )
public int getRowCount(java.lang.String tableOid)
Gets the total number of rows in a table.If the agent is not running it returns -1.
public java.util.Vector getInstances(java.lang.String tableOid)
Gets all the instances in a table
public java.lang.String getNextInstance(java.lang.String tableOid,
java.lang.String instance)
Gets the instance next to the specified instance
instance - - the instance value
For e.g.
public void maskNode(java.lang.String objectId,
java.lang.String instance,
java.lang.String maskValue)
objectId - is the object identifier (without the instance)
of the mib nodeinstance - is the instance of the node that should be
masked, for scalar nodes this should be ".0"maskValue - can be either "True" or "False"
For e.g.
To enable the mask for the scalar node 'sysName'
scriptinterface.maskNode(".1.3.6.1.2.1.1.5",".0","True")
To disable the mask for the node 'ifAdminStatus' for the instance '.1'
scriptinterface.maskNode(".1.3.6.1.2.1.2.2.1.7",".1","False")
public java.lang.String getNodeValue(java.lang.String objectId,
java.lang.String instance)
objectId - is the object identifier (without the instance)
of the mib node This will return the value as a Stringinstance - is the instance of the node whose value
should be obtained, for scalar nodes this should be ".0"
For e.g.
To get the current value of the counter 'snmpInPkts' include
the following lines in the script file
value = scriptinterface.getNodeValue(".1.3.6.1.2.1.11.1",".0")
print "Value of SnmpInPkts is = ",value
public int getTotalColumns(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningtableEntryOid - The oid of the tableEntry node
public java.lang.String[] getAllColumnByNames(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningtableEntryOid - The oid of the tableEntry node
public java.lang.String[] getAllColumnByOids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningtableEntryOid - The oid of the tableEntry node
public java.lang.String[] getAllIndices(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningtableEntryOid - The oid of the tableEntry node
public void sendV1Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType)
mgrName - - the name of the manager to which the trap has
to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityenterpriseOid - - the Enterprise OIDgenericType - - the Generic TypespecificType - - the Specific Type
For e.g.
scriptinterface.sendV1Trap("localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1",6,3)
public void sendV1Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the trap has
to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityenterpriseOid - - the Enterprise OIDgenericType - - the Generic TypespecificType - - the Specific TypevarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["aaaa","lucy","3"],String)
scriptinterface.sendV1Trap("localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1",6,3,objectid,nodetypes,values)
public void sendV2Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID)
mgrName - - the name of the manager to which the trap
has to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communitytrapOID - - the value for the SnmpTrapOid
For e.g.
scriptinterface.sendV2Trap("localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1")
public void sendV2Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the trap
has to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communitytrapOID - - the value for the SnmpTrapOidvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV2Trap(mgrName,mgrPort,community,trapOID,objectid,nodetypes,values)
public void sendV3Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
mgrName - - the name of the manager to which the trap has to
be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the context
For e.g.
public void sendV3Trap(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the trap has to
be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the contextvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV3Trap("localhost",3000,"public",".1.3.6.1.6.3.1.1.4.1","noAuthUser","noAuth",objectid,nodetypes,values)
public boolean modifyTimerScriptParameters(java.lang.String ipAddress,
int port,
java.lang.String scriptFile,
java.lang.String date,
long timerInterval,
int noOfTimes)
ipAddress - - IP Address of the SNMP agent in which parameters for
timer scripts have to be modifiedport - - Port of the SNMP agent in which parameters for
timer scripts have to be modifiedscriptFile - - The name of the script file to be modified.date - - The time at which the script to be executed.timerInterval - - The interval in milliseconds at which the script
should be executednoOfTimes - - The number of times the scriptFile should be executed
public boolean modifyTimerScriptParameters(java.lang.String scriptFile,
java.lang.String date,
long timerInterval,
int noOfTimes)
scriptFile - - The name of the script file to be modified.date - - The time at which the script to be executed.timerInterval - - The interval in milliseconds at which the script
should be executednoOfTimes - - The number of times the scriptFile should be executed
public void sendInform(java.lang.String mgrName,
java.lang.String mgrPort,
java.lang.String community,
java.lang.String sysUpTime,
java.lang.String snmpTrapOid)
mgrName - - the name of the manager to which the inform has to
be sentmgrPort - - the port at which the manager is listening for
incoming inform requestscommunity - - the snmp communitysysUpTime - - the System UpTimesnmpTrapOid - - the value of the snmpTrapOid
For e.g.
scriptinterface.sendInform("localhost","3000","public","10000",".1.3.6.1.6.3.1.1.4.1")
public void sendInform(java.lang.String mgrName,
java.lang.String mgrPort,
java.lang.String community,
java.lang.String sysUpTime,
java.lang.String snmpTrapOid,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the inform has to
be sentmgrPort - - the port at which the manager is listening for
incoming inform requestscommunity - - the snmp communitysysUpTime - - the System UpTimesnmpTrapOid - - the value of the snmpTrapOidvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the informvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendInform(mgrName,mgrPort,community,sysUpTime,snmpTrapOid,objectid,nodetypes,values)
public void sendV2Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String informOID)
mgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityinformOID - - the value for the InformTrapOid
For e.g.
scriptinterface.sendV2Inform("localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1")
public void sendV2Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String informOID)
agentAddress - - the name of the Agent from which the inform
has to comeagentPort - - the port from which the Agent is sending
informmgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityinformOID - - the value for the InformTrapOid
For e.g.
scriptinterface.sendV2Inform("1.1.1.1", 8001, "localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1")
public void sendV2Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV2Inform(mgrName,mgrPort,community,trapOID,objectid,nodetypes,values)
public void sendV2Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
agentAddress - - the name of the Agent from which the inform
has to comeagentPort - - the port from which the Agent is sending
informmgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV2Inform("localhost", 161, mgrName,mgrPort,community,trapOID,objectid,nodetypes,values)
public void sendV3Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
mgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the context
For e.g.
public void sendV3Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
agentAddress - - the name of the Agent from which the inform
has to comeagentPort - - the port from which the Agent is sending
informmgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the context
For e.g.
public void sendV3Inform(java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
mgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the contextvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV3Inform("localhost",3000,"public",".1.3.6.1.6.3.1.1.4.1","noAuthUser","noAuth",objectid,nodetypes,values)
public void sendV3Inform(java.lang.String agentAddress,
int agentPort,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
agentAddress - - the name of the Agent from which the inform
has to comeagentPort - - the port from which the Agent is sending
informmgrName - - the name of the manager to which the inform
has to be sentmgrPort - - the port at which the manager is listening for
incoming informcommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the contextvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV3Inform("localhost", 161, "localhost",3000,"public",".1.3.6.1.6.3.1.1.4.1","noAuthUser","noAuth",objectid,nodetypes,values)
public java.lang.String getErrStat()
public java.lang.String getErrIndex()
public void maskNode(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String maskValue)
ipAddress - is the agent addressport - is the agent portScriptInterface#maskNode(String objectId,String instance,String maskValue)
public void deleteRow(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid,
java.lang.String instance)
ipAddress - is the agent addressport - is the agent portScriptInterface#deleteRow(String tableEntryOid,String instance)
public void deleteAllRows(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableEntryOid)
ipAddress - is the agent addressport - is the agent portScriptInterface#deleteAllRows(String tableEntryOid)
public void updateNodeValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String value)
ipAddress - is the agent addressport - is the agent portobjectId - is the object identifier (including the instance)
of the mib node whose value has to be updatedvalue - is the value to be assigned to the nodeScriptInterface#updateValue(String objectId,String instance,String value)
public void updateValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance,
java.lang.String value,
java.lang.String simType)
ipAddress - is the agent addressport - is the agent portScriptInterface#updateValue(String objectId,String instance,String value,String simType)
public java.lang.String getNodeValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String objectId,
java.lang.String instance)
ipAddress - is the agent addressport - is the agent portScriptInterface#getNodeValue(String objectId,String instance)
public void insertRow(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid,
java.lang.String[] objectId,
java.lang.String[] values,
java.lang.String[] simTypes)
ipAddress - is the agent addressport - is the agent portScriptInterface#insertRow(String tableOid,String[] objectId,String[] values,String[] simTypes)
public int getRowCount(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid)
ipAddress - is the agent addressport - is the agent portScriptInterface#getRowCount(String tableOid)
public java.util.Vector getInstances(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid)
ipAddress - is the agent addressport - is the agent portScriptInterface#getInstances(String tableOid)
public java.lang.String getNextInstance(java.lang.String ipAddress,
java.lang.String port,
java.lang.String tableOid,
java.lang.String instance)
ipAddress - is the agent addressport - is the agent portScriptInterface#getNextInstance(String tableOid,String instance)public java.lang.String getCurrentOID()
Gets the current OID
public int getCurrentColumn()
public java.lang.String getCurrentInstance()
Gets the current instance i.e. the instance in the incoming OID
public int getRequestType()
Gets the request type *
public int getScriptConditionForSnmpAgent()
Gets the condition for the script in execution. The condition can be before request or after request. The values returned will be any of the following : 0 - Before request 1 - After request
public java.lang.String getSnmpIPAddress()
Gets the IP Address of the agent for which the request has come
public java.lang.String getIPAddress()
Gets the IP Address of the agent for which the request has come
public int getSnmpPort()
Gets the port at which the agent is running
public java.lang.String getCurrentValue()
Gets the current value i.e. the value in the incoming Set Request
public void terminateOperation(int errorNumber)
Terminates the current operation i.e. it terminates a Get, GetNext, Set operation
errorNumber - - the error to be thrown after terminating
the operation. Should be a number between 0 and 7
case 0 - "too big" case 1 - "no such object" case 2 - "no such instance" case 3 - "end of mib view" case 4 - "bad value" case 5 - "read only" case 6 - "general error" case 7 - "no access"
For e.g.
To terminate the Get request on sysContact and return "general error"
configure a script with the condition "Before Processing Get" on sysContact
and enter the following line in the script
scriptinterface.terminateOperation(6)
public boolean startAgent(java.lang.String uniqueName)
registerToRMI method here. This method is
to register the RMI interface Object AgentSimulatorListener.
This method call be called at a startUp Script, so that the
simulator registers its object reference to the RMI Registry.
public boolean stopAgent(java.lang.String uniqueName)
public java.lang.String getSnmpOidForNodeName(java.lang.String nodeName)
nodeName - The nodeName of the SNMP node
public java.lang.String getSnmpOidForNodeName(java.lang.String ipAddress,
int port,
java.lang.String nodeName)
nodeName - The nodeName of the SNMP node
public int getTotalColumns(java.lang.String tableEntryOid)
tableEntryOid - The oid of the tableEntry nodepublic java.lang.String[] getAllColumnByNames(java.lang.String tableEntryOid)
tableEntryOid - The oid of the tableEntry nodepublic java.lang.String[] getAllColumnByOids(java.lang.String tableEntryOid)
tableEntryOid - The oid of the tableEntry nodepublic java.lang.String[] getAllIndices(java.lang.String tableEntryOid)
tableEntryOid - The oid of the tableEntry nodepublic void sendTrap(java.lang.String associatedVariable)
associatedVariable - The associated variable name
corresponding to the trap configured inside the trap
configuration ui in simulator
public void sendTrap(java.lang.String trapName,
java.lang.String enterpriseOID)
enterpriseOID - is the enterpriseOID of to be sent
in trap pdu
public void sendTrap(java.lang.String associatedVariable,
java.lang.String ipAddress,
java.lang.String snmpPort)
public java.lang.String getCurrentOIDWithInstance()
Gets the current OID with the instance appended to it.
public java.lang.String getConfigDirectory()
Gets the current working directory i.e. if MIBs are loaded then it will point out to the latest instance directory and if configuration is loaded then it will point out to the configuration directory
public void sendV1Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap has
to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityenterpriseOid - - the Enterprise OIDgenericType - - the Generic TypespecificType - - the Specific Type
For e.g.
scriptinterface.sendV1Trap("192.168.1.109", "8001","localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1",6,3)
public void sendV1Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOid,
int genericType,
int specificType,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap has
to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityenterpriseOid - - the Enterprise OIDgenericType - - the Generic TypespecificType - - the Specific TypevarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["aaaa","lucy","3"],String)
scriptinterface.sendV1Trap("192.168.1.109", "8001","localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1",6,3,objectid,nodetypes,values)
public void sendV2Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap
has to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communitytrapOID - - the value for the SnmpTrapOid
For e.g.
scriptinterface.sendV2Trap("192.168.1.109", "8001","localhost",162,"public",".1.3.6.1.4.1.2162.4.1.1")
public void sendV2Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String trapOID,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap
has to be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communitytrapOID - - the value for the SnmpTrapOidvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV2Trap("192.168.1.109", "8001", mgrName,mgrPort,community,trapOID,objectid,nodetypes,values)
public void sendV3Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap has to
be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the context
For e.g.
public void sendV3Trap(java.lang.String ipAddress,
java.lang.String port,
java.lang.String mgrName,
int mgrPort,
java.lang.String community,
java.lang.String enterpriseOID,
java.lang.String userName,
java.lang.String contextName,
java.lang.String[] varbindOid,
java.lang.String[] varbindTypes,
java.lang.String[] varbindValues)
ipAddress - is the ipAddress of the deviceport - - the port at which the agent is runningmgrName - - the name of the manager to which the trap has to
be sentmgrPort - - the port at which the manager is listening for
incoming trapscommunity - - the snmp communityuserName - - the snmp v3 usercontextName - - the contextvarbindOid - - a string array giving the objectid of the varbinds
to be sent with the trapvarbindValues - - a string array giving the values for the above
specified varbindsvarbindTypes - - a string array giving the type of the above specified
varbind. This should be one of the following :
For e.g.
objectid = array([".1.3.6.1.2.1.1.4.0",".1.3.6.1.2.1.1.5.0",".1.3.6.1.2.1.1.7.0"],String)
nodetypes = array(["String","String","Integer"],String)
values = array(["sys-admin","test","3"],String)
scriptinterface.sendV3Trap("192.168.1.109", "8001", "localhost",3000,"public",".1.3.6.1.6.3.1.1.4.1","noAuthUser","noAuth",objectid,nodetypes,values)
public void setSnmpCharacterEncoding(java.lang.String encode)
encode - is the encoding of characters for SNMP agent
ISO8859_1 for English
GB2312 for Chinese and
ISO-2022-JP for Japanese
public java.lang.String getScriptFile(java.lang.String command,
java.lang.String modeis)
command - - Command for which we require the Script filemodeis - - The mode in which the command is present
public void updateScriptFile(java.lang.String command,
java.lang.String scriptFile,
java.lang.String modeis)
command - - Command for which the Script file has to be uploadedscriptFile - - ScriptFile to be uploadedmodeis - - The mode in which the command is present
For e.g public java.lang.String getCurrentCommand()
public int getCurrentLevel()
public void changeMode(int mode)
mode - - Mode to be changed (Note :Each and every mode is represented
using an integer value )
The Integer value for the Modes are :
User - 5
Enable - 6
Config - 7
Config-if - 9
Config-rip - 10
Config-line - 11
Config-vlan - 12
Config-bgp - 13
Config-ospf - 14
For e.g public java.lang.String getCmdWord(int index)
index - - Number indicating which part of the command is required.
public void updateHost(java.lang.String name)
name - - New Name for the host.
For e.g public java.lang.String getInterfaceStatus()
public java.lang.String getMode()
public void addParameters(java.lang.String paramKey,
java.lang.String paramValue)
paramKey - - The Key with which the value has to be stored.paramValue - - Value to be stored .
For e.g public java.lang.String getParamValue(java.lang.String paramKey)
paramKey - - The Key for the required value .
public void deleteParameters(java.lang.String paramKey)
paramKey - - Key whose entity is to be deleted
For e.g public java.util.Vector getParamListValues(java.lang.String paramKey)
paramKey - - A part of the paramKey .
public void setConnectionTime(int time)
time - - New sessiontime in seconds.
For e.g public void showHistory()
public void strAppend(java.lang.String response)
response - - String which has to be recieved as the response.
For e.g public java.lang.String executeScript(java.lang.String scriptFile)
public java.util.Vector getParamKeyList(java.lang.String paramKey)
public void updateIPAddress(java.lang.String ipAddress)
public void setEnablePassword(java.lang.String password)
password - - password to be set
For e.g public java.lang.String getEnablePassword()
public boolean isInterfaceUp(java.lang.String ipAddress)
public int getRoundTripTime()
public int getMaxRoundTripTime()
public int getMinRoundTripTime()
public void setPassword(java.lang.String password)
password - - New password to be set
For e.g public java.lang.String getPassword()
public void noEnablePassword()
public java.lang.String getUserName()
public boolean getEnableFlag()
public java.lang.String getNetworkAddress(java.lang.String ipAddress)
ipAddress - - IPAddress of the device
public java.lang.String getHighestIPAddress(java.util.Vector ipAddr)
ipAddr - - The vector which contains a bunch of IPAddress
public java.lang.String getTelnetRootDir()
public java.lang.String execDisplayCommand(java.lang.String cmd)
cmd - - Command which satisfies the above conditions.
public java.lang.String executeGlobalCmd(java.lang.String cmd)
cmd - - Command which satisfies the above conditions.
public void executeTelnetCmd(java.lang.String cmd)
cmd - - Command which satisfies the above conditions.
For e.g public boolean changeDirectory(java.lang.String dir)
dir - - The directory to be changed .
public void execGlobalTelnetCmd(java.lang.String cmd)
cmd - - Command which satisfies the above conditions.
For e.g public java.lang.String getDeviceName()
public java.lang.String getTelnetCommands(int dev)
dev - - 1 For Linux/Solaris device
2 For Windows device
public boolean addSnmpAgent(java.lang.String devName,
java.lang.String ipAddress,
java.lang.String port,
java.lang.String readCommunity,
java.lang.String writeCommunity,
java.lang.String tftpPort)
devName - - name of the device present in the Device TreeipAddress - - IP Address of the SNMP agent to be addedport - - Port at which the SNMP agent will start/listenreadCommunity - - The read community of the SNMP agent to be addedwriteCommunity - - The write community of the SNMP agent to be addedtftpPort - - TFTP port at which the SNMP agent will listen for TFTP request
public boolean deleteSnmpAgent(java.lang.String ipAddress,
java.lang.String port)
ipAddress - - IP Address of the SNMP agent to be deletedport - - Port of the SNMP agent to be deleted
public java.util.ArrayList getAllDeviceNames()
public int getNoOfSnmpAgentsRunning()
public boolean isSnmpAgentRunning(java.lang.String ipAddress,
java.lang.String port)
public boolean stopAllTimerTraps()
public boolean stopAllTimerInforms()
public boolean stopAllTimerScripts()
public boolean stopTimerScripts(java.lang.String ipAddress,
java.lang.String port)
ipAddress - - IP Address of the SNMP agent in which
timer scripts have to be stoppedport - - Port of the SNMP agent in which
timer scripts have to be stopped
public boolean stopTimerTraps(java.lang.String ipAddress,
java.lang.String port)
ipAddress - - IP Address of the SNMP agent in which
timer traps have to be stoppedport - - Port of the SNMP agent in which
timer traps have to be stopped
public boolean downInterface(java.lang.String ipAddress,
int port,
java.lang.String ifIndex)
ipAddress - - IP Address of the SNMP agent in which
the interface has to be shut downport - - Port of the SNMP agent in which
the interface has to be shut downifIndex - - The index of the interface which has to be shut down
public boolean upInterface(java.lang.String ipAddress,
int port,
java.lang.String ifIndex)
ipAddress - - IP Address of the SNMP agent in which
the interface has to be activatedport - - Port of the SNMP agent in which
the interface has to be activatedifIndex - - The index of the interface which has to be activated
public boolean upInterface(java.lang.String ifIndex)
ifIndex - - The index of the interface which has to be activated
public boolean downInterface(java.lang.String ifIndex)
ifIndex - - The index of the interface which has to be shutdown
public void addAccessId(java.lang.String commandCode,
java.lang.String accessId)
Adds an accessId for a Command Code. If the accessId to be added has more than one parameters, then the accessId should be separated by commas/colon. If the accessId has parameters, namely, Termination Point 1 and Termination Point 2, then the accessId should hold the value such as "point1,point2".
For example,
to add a new accessId, add the following line to the script file
tl1scriptinterface.addAccessId("RTRV-EQPT", "ALL")
where "RTRV-EQPT" is the commandCode, "ALL" is the accessId.
commandCode - is the CommandCode present in the agent.accessId - is the new accessId to add for the commandCode.
public void deleteAccessId(java.lang.String commandCode,
java.lang.String accessId)
Deletes an accessId for a Command Code.
For example,
to delete an accessId for a commandCode, add the following line to the script file
tl1scriptinterface.deleteAccessId("RTRV-NE", "ALL")
where "RTRV-NE" is the commandCode, "ALL" is the accessId.
commandCode - is the CommandCode present in the agent.accessId - is the accessId to be deleted.
public void addMsgPayLoad(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Adds a new Message PayLoad. This adds a MessagePayLoad for a commandCode, accessId combination. Certain command codes may not have accessId defined at all. In such cases, accessId parameter should be an empty string(""). While adding make sure you don't add a message payload block for a command code which doesn't define one.
For example,
to add a Message PayLoad, add the following line to the script file
tl1scriptinterface.addMsgPayLoad("ED-PID","AID", "OLDPWD,NEWPWD")
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the new MessagePayLoad to add.
This method will also add the accessId if it is not present.
commandCode - is the CommandCode present in the agent.accessId - is the accessId to be added.msgPayLoad - is the MessagePayLoad to be added.
public void delMsgPayLoad(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Deletes a Message PayLoad. This deletes a MessagePayLoad for a commandCode, accessId combination. Certain command codes may not have accessId defined at all. In such cases, accessId parameter should be an empty string("").
For example,
to delete a Message PayLoad, add the following line to the script file
tl1scriptinterface.delMsgPayLoad("ED-PID","AID", "OLDPWD,NEWPWD")
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad to delete.
commandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the MessagePayLoad.msgPayLoad - is the MessagePayLoad to be deleted.
public void setComplCode(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int complCode)
Sets the Completion Code(COMPLD,DENY) for a commandCode, accessId, msgPayLoad combination.
For example, to set the completion code, add the following line to the the script file
tl1scriptinterface.setComplCode("ED-PID","AID", "OLDPWD,NEWPWD",1)
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad and 1 represents COMPLD. The list of values that can be supplied is :
commandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.complCode - is the completion code to be set (COMPLD/DENY).
public void setAckMessage(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int ackNO)
Sets the Acknowledgement Message for a commandCode, accessId, msgPayLoad combination.
For example, to set the acknowledgement message, add the following line to the the script file
tl1scriptinterface.setAckMessage("ED-PID","AID", "OLDPWD,NEWPWD",1)
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad and 1 represents IN PROGRESS. The list of values that can be supplied is :
commandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.
public void addLines(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. You can add a line for a valid response or error response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
commandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for line to be added.paramValues - is the list of values for the parameter names.
public void delLines(java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean responseType,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. You can delete a line for a valid response or error response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
commandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.responseType - is a boolean representing whether the line is to be deleted for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for the line to be deletedparamValues - is the list of values for the parameter names.
public void sendDenyMessage(java.lang.String errorCode,
java.lang.String explanation)
Sends a deny message with the provided errorCode and explanation
public void sendResponseMessage(java.lang.String[] paramNames,
java.lang.String[] paramPosType,
java.lang.String[] delimiters,
java.util.Vector paramValuesVector,
java.lang.String[] lineTypes,
int completionCode)
Sends a Response Message with the parameters defined inside the script
public java.lang.String getCurrentCommandCode()
Gets the Command code that comes in the request.
public java.lang.String getCurrentAID()
Gets the accessId that comes in the request. If the accessId is not given in the request, this method returns an empty string.
public java.lang.String getCurrentMPB()
Gets the msgPayLoad that comes in the request. If the msgPayLoad is not given in the request, this method returns an empty string.
public java.lang.String getTL1ConfigDirectory()
Gets the current working directory i.e. if TCS are loaded then it will point out to the latest instance directory and if configuration is loaded then it will point out to the configuration directory
public boolean startAgent(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tl1Port)
This method is used to start a Snmp/Tl1 agent using the ipAddress and Port given. This will be used only through Network Designer. tl1Port can be left blank if you are not going to start the snmp agent. snmpPort can be left blank if you are going to start the Tl1 agent.
ipAddress - the IP Address of the TL1 agent to be started.snmpPort - the port at which the snmp agent should start.tl1Port - the port at which the tl1 agent should start.
public boolean stopAgent(java.lang.String ipAddress,
java.lang.String snmpPort,
java.lang.String tl1Port)
This method is used to stop a Snmp/Tl1 agent using the ipAddress and Port given. This will be used only through Network Designer. tl1Port can be left blank if you are not going to stop the snmp agent. snmpPort can be left blank if you are going to stop the TL1 agent.
ipAddress - the IP Address of the TL1 agent to be stopped.snmpPort - the port at which the snmp agent is listening.tl1Port - the port at which the tl1 agent is listening.
public int getNumberOfAids(java.lang.String commandCode)
Gets the number of Access Identifiers configured for a command code.
public int getNumberOfMpbs(java.lang.String commandCode,
java.lang.String accessID)
Gets the number of Message PayLoad configured for a command code and access identifier combination.
public java.util.Vector getAllAids(java.lang.String commandCode)
Gets all the Access Identifiers configured for a command code.
public java.util.Vector getAllMpbs(java.lang.String commandCode,
java.lang.String accessID)
Gets all the Message Payload configured for a command code and access identifier combination.
public boolean isAidExists(java.lang.String commandCode,
java.lang.String accessID)
Checks if the given access identifier already exists for the command code.
public boolean isMpbExists(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad)
Checks if the given message payload already exists for the command code and access identifer combination.
public void sendAutonomousMessage(java.lang.String autoCode,
java.lang.String almDescr,
int numberOfTimes,
int interval)
Sends autonomous message a specified number of times with specified time interval .
public void sendAutonomousMessage(java.lang.String autoCode,
java.lang.String almDescr)
Sends a single autonomous message for the given autoCode and almDescr.
public java.lang.String getTL1IPAddress()
Gets the current IPAddress of the agent being queried.
public int getTL1Port()
Gets the current port of the agent being queried.
public void updateParamValue(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. A particular line is retrieved using the uniquePName and uniquePValue variabled. Once a line is chosen for updation, the pNameToModify denotes the parameter name to modify and the modifyValue denotes the value to be updated for the paramter name, pNameToModify.
commandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter valuepNameToModify - denotes the paramter name to modifymodifyValue - denotes the paramter value to be updated.
public void deleteLine(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. The line to be deleted is chosen by the uniquePName and uniquePValue variables.
commandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public java.util.Hashtable getLine(java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. The line to be returned is chosen by the uniquePName and uniquePValue variables.
commandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public int getScriptConditionForTL1Agent()
Gets the condition for the script in execution. The condition can be before request or after request. The values returned will be any of the following : 1 - Before request 2 - After request
public void addLines(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to an autonomous code and alarm description combination. You can add a line only for a valid autonomous response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
autoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for line to be added.paramValues - is the list of values for the parameter names.
public void delLines(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) for a autonomouse code and alarm description combination. You can delete a line for a valid response only . The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
a valid response/error response.
autoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for the line to be deletedparamValues - is the list of values for the parameter names.
public java.util.Hashtable getLine(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. The line to be returned is chosen by the uniquePName and uniquePValue variables.
autoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public void updateParamValue(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. A particular line is retrieved using the uniquePName and uniquePValue variables. Once a line is chosen for updation, the pNameToModify denotes the parameter name to modify and the modifyValue denotes the value to be updated for the paramter name, pNameToModify.
autoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter valuepNameToModify - denotes the paramter name to modifymodifyValue - denotes the paramter value to be updated.
public void deleteLine(java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. The line to be deleted is chosen by the uniquePName and uniquePValue variables.
autoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public int getNumberOfAids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode)
Gets the number of Access Identifiers configured for a command code.
public int getNumberOfMpbs(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Gets the number of Message PayLoad configured for a command code and access identifier combination.
public java.util.Vector getAllAids(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode)
Gets all the Access Identifiers configured for a command code.
public java.util.Vector getAllMpbs(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Gets all the Message Payload configured for a command code and access identifier combination.
public boolean isAidExists(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID)
Checks if the given access identifier already exists for the command code.
public boolean isMpbExists(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad)
Checks if the given message payload already exists for the command code and access identifer combination.
public java.util.Hashtable getLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. The line to be returned is chosen by the uniquePName and uniquePValue variables.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public void deleteLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. The line to be deleted is chosen by the uniquePName and uniquePValue variables.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public void updateParamValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessID,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. A particular line is retrieved using the uniquePName and uniquePValue variabled. Once a line is chosen for updation, the pNameToModify denotes the parameter name to modify and the modifyValue denotes the value to be updated for the paramter name, pNameToModify.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter valuepNameToModify - denotes the paramter name to modifymodifyValue - denotes the paramter value to be updated.
public void addLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to an autonomous code and alarm description combination. You can add a line only for a valid autonomous response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningautoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for line to be added.paramValues - is the list of values for the parameter names.
public void delLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) for a autonomouse code and alarm description combination. You can delete a line for a valid response only . The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
a valid response/error response.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningautoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for the line to be deletedparamValues - is the list of values for the parameter names.
public java.util.Hashtable getLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Gets a line information with parameter name as the key and the parameter value as the value. The line to be returned is chosen by the uniquePName and uniquePValue variables.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningautoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public void updateParamValue(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue,
java.lang.String pNameToModify,
java.lang.String modifyValue)
Updates the value of a parameter in a line. A particular line is retrieved using the uniquePName and uniquePValue variables. Once a line is chosen for updation, the pNameToModify denotes the parameter name to modify and the modifyValue denotes the value to be updated for the paramter name, pNameToModify.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningautoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter valuepNameToModify - denotes the paramter name to modifymodifyValue - denotes the paramter value to be updated.
public void deleteLine(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String alarmDescr,
int lineType,
java.lang.String uniquePName,
java.lang.String uniquePValue)
Deletes a line. The line to be deleted is chosen by the uniquePName and uniquePValue variables.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningautoCode - is the autonomous code present in the agent.alarmDescr - is the alarm description corresponding to the autoCode.lineType - represents whether the line is quoted/unquoted.uniquePName - denotes the unqiue parameter nameuniquePValue - denotes the unique parameter value
public void addAccessId(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId)
Adds an accessId for a Command Code. If the accessId to be added has more than one parameters, then the accessId should be separated by commas/colon. If the accessId has parameters, namely, Termination Point 1 and Termination Point 2, then the accessId should hold the value such as "point1,point2".
For example,
to add a new accessId, add the following line to the script file
tl1scriptinterface.addAccessId("RTRV-EQPT", "ALL")
where "RTRV-EQPT" is the commandCode, "ALL" is the accessId.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the new accessId to add for the commandCode.
public void deleteAccessId(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId)
Deletes an accessId for a Command Code.
For example,
to delete an accessId for a commandCode, add the following line to the script file
tl1scriptinterface.deleteAccessId("RTRV-NE", "ALL")
where "RTRV-NE" is the commandCode, "ALL" is the accessId.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId to be deleted.
public void addMsgPayLoad(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Adds a new Message PayLoad. This adds a MessagePayLoad for a commandCode, accessId combination. Certain command codes may not have accessId defined at all. In such cases, accessId parameter should be an empty string(""). While adding make sure you don't add a message payload block for a command code which doesn't define one.
For example,
to add a Message PayLoad, add the following line to the script file
tl1scriptinterface.addMsgPayLoad("ED-PID","AID", "OLDPWD,NEWPWD")
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the new MessagePayLoad to add.
This method will also add the accessId if it is not present.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId to be added.msgPayLoad - is the MessagePayLoad to be added.
public void delMsgPayLoad(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad)
Deletes a Message PayLoad. This deletes a MessagePayLoad for a commandCode, accessId combination. Certain command codes may not have accessId defined at all. In such cases, accessId parameter should be an empty string("").
For example,
to delete a Message PayLoad, add the following line to the script file
tl1scriptinterface.delMsgPayLoad("ED-PID","AID", "OLDPWD,NEWPWD")
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad to delete.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the MessagePayLoad.msgPayLoad - is the MessagePayLoad to be deleted.
public void setComplCode(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int complCode)
Sets the Completion Code(COMPLD,DENY) for a commandCode, accessId, msgPayLoad combination.
For example, to set the completion code, add the following line to the the script file
tl1scriptinterface.setComplCode("ED-PID","AID", "OLDPWD,NEWPWD",1)
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad and 1 represents COMPLD. The list of values that can be supplied is :
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.complCode - is the completion code to be set (COMPLD/DENY).
public void setAckMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
int ackNO)
Sets the Acknowledgement Message for a commandCode, accessId, msgPayLoad combination.
For example, to set the acknowledgement message, add the following line to the the script file
tl1scriptinterface.setAckMessage("ED-PID","AID", "OLDPWD,NEWPWD",1)
where "ED-PID" is the commandCode, "AID" is the accessId and "OLDPWD,NEWPWD" is the MessagePayLoad and 1 represents IN PROGRESS. The list of values that can be supplied is :
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.
public void addLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean isValid,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Adds a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. You can add a line for a valid response or error response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.isValid - is a boolean representing whether the line is to be added for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for line to be added.paramValues - is the list of values for the parameter names.
public void delLines(java.lang.String ipAddress,
java.lang.String port,
java.lang.String commandCode,
java.lang.String accessId,
java.lang.String msgPayLoad,
boolean responseType,
int lineType,
java.lang.String[] paramNames,
java.lang.String[] paramValues)
Deletes a line(quoted/unquoted) to a commandCode, accessId and msgPayLoad combination. You can delete a line for a valid response or error response. The linetype can be quoted or unquoted. The list of paramter names depends on :
lineType can have the following values :
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is runningcommandCode - is the CommandCode present in the agent.accessId - is the accessId corresponding to the commandCode.msgPayLoad - is the MessagePayLoad corresponding to the accessId.responseType - is a boolean representing whether the line is to be deleted for
a valid response/error response.lineType - represents whether the line is quoted/unquoted.paramNames - is the list of parameter names available for the line to be deletedparamValues - is the list of values for the parameter names.
public void sendAutonomousMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String almDescr,
int numberOfTimes,
int interval)
Sends autonomous message a specified number of times with specified time interval. The autonomous message will be sent from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable.
public void sendAutonomousMessage(java.lang.String ipAddress,
java.lang.String port,
java.lang.String autoCode,
java.lang.String almDescr)
Sends a single autonomous message for the given autoCode and almDescr. The autonomous message will be sent from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable.
public void clearAllAutonomousMessages()
Clears all the autonomous messages that were sent previously from all the TL1 agents in the selected network
public void clearAutonomousMessagesInDevice(java.lang.String ipAddress,
java.lang.String port)
Clears all the autonomous messages that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is running
public void sendAutonomousMessagesInDevice(java.lang.String ipAddress,
java.lang.String port)
Sends all the autonomous messages that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable.
public void sendAutonomousMessages()
Sends all the autonomous messages that were sent previously from all the TL1 agents in the selected network
public java.util.Vector getAutonomousDetails()
Gets all the autonomous messages details that were sent previously from all the TL1 agents in the selected network
public java.util.Vector getAutonomousDetailsForDevice(java.lang.String ipAddress,
java.lang.String port)
Gets all the autonomous messages details that were sent previously from the TL1 agent whose IP Address is specified in the ipAddress variable and whose listening port is in the port variable.
ipAddress - is the ipAddress of the deviceport - is the port at which the agent is running
public boolean startTftpServer(java.lang.String ipAddress,
java.lang.String port,
java.lang.String rootDir)
ipAddress - The IP address at which the TFTP server to be startedport - The port in the host at which TFTP server to be started
public boolean stopTftpServer(java.lang.String ipAddress,
java.lang.String port)
ipAddress - The IP address at which the TFTP server is runningport - The port in the host at which TFTP server is running
public boolean uploadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol)
ipAddress - - The host at which the TFTP server is runningport - - The port in the host at which the TFTP server is runningsource - - The source file to be get or puttarget - - The destination file namemode - - The mode of transfer either '0 for ascii' or '1 for binary'protocol - - The protocol to be used for uploading file
public boolean uploadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol,
java.lang.String userName,
java.lang.String password)
ipAddress - - The host at which the FTP server is runningport - - The port in the host at which the FTP server is runningsource - - The source file to be uploadedtarget - - The destination file namemode - - The mode of transfer either '0 for ascii' or '1 for binary'protocol - - The protocol to be used for uploading filepassword - - The password for the user for the protocol connection
public boolean downloadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol)
ipAddress - - The host at which the TFTP server is runningport - - The port in the host at which the TFTP server is runningsource - - The source file to be downloadedtarget - - The destination file namemode - - The mode of transfer either '0 for ascii' or '1 for binary'protocol - - The protocol to be used for uploading file
public boolean downloadFile(java.lang.String ipAddress,
int port,
java.lang.String source,
java.lang.String target,
int mode,
java.lang.String protocol,
java.lang.String userName,
java.lang.String password)
ipAddress - - The host at which the FTP server is runningport - - The port in the host at which the FTP server is runningsource - - The source file to be downloadedtarget - - The destination file namemode - - The mode of transfer either '0 for ascii' or '1 for binary'protocol - - The protocol to be used for uploading file
public boolean isTftpRunning(java.lang.String ipAddress,
int port)
ipAddress - - The host at which the TFTP server is running or notport - - The port in host at which the TFTP server is running or not
public boolean addMibFileToDevice(java.lang.String ipAddress,
int port,
java.lang.String mibFile)
ipAddress - - IP Address of the SNMP agent to be addedport - - Port at which the SNMP agent will start/listenmibFile - - The mib file to be added to the device
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||