The device object represents a device script and contains dynamic properties defined
for the current device. In user-created devices, these properties are defined in the
scripts.
Properties
Name | Type | Description |
ipAddr | String | The IP address of the network device. |
name | String | The name of the network device. |
Methods
Return Value | Name | Description |
void | addBridgePortMapping( String index , String name ) | Adds an index/name mapping for bridge table ports. |
void | addIfPortMapping( String index , String name ) | Adds an index/name mapping for interface table ports. |
void | addTrunkPort( String portName ) | Registers portName as a trunk port. Trunk ports will not store bridge table information. |
void | clearBridgePortMapping() | Removes all bridge port mappings. |
void | clearIfPortMapping() | Removes all interface port mappings. |
Map | getBridgePortMapping() | Returns the complete mapping of bridge ports. |
String | getBridgePortMapping( String index ) | Returns the port name for the bridge port index. |
Map | getIfPortMapping() | Returns the complete mapping of interface ports. |
String | getIfPortMapping( String index ) | Returns the port name for the interface port index. |
void | storeBridgeInfo( String macAddr , String switchIP , String port , String status , Integer portCount ) | Saves the bridge table information to the database. |
void | storeRouteTable( List ipAddressList , List interfaceList , List netmaskList ) | Saves the subnet routing information to the database. |
Sample usage
var switchIP = device.ipAddr;