This topic explains the following about Device Snapshot View:
For a new map created or existing Web NMS default map, Web NMS provides an option to add Device Snapshot View to display all the details related to the managed object. Event, Alarm panels can be added as a tab below the map. User defined custom panels can also added.
Enabling the Device Snapshot View Panel
To enable the Device Snapshot View Panel, set the DEVICE_VIEW parameter to true in the serverparameters.conf file available in the <Web NMS Home>/conf directory.
And set the parameters MULTIPLE_ALERT_VIEW and MULTIPLE_EVENT_VIEW to true in the clientparamerter.conf file present under <Web NMS Home>/conf directory.
On enabling, each map panel will be added with the tab panels below the map view (Device View). The tab panels will be added based on views specified in the map property tabPanels.
Enabling the Menu Entry for Device View
Uncomment the following entries in the <Web NMS Home>/html/defaultToAllUsers/mapmenu.xml file.
<!--MENU-ITEM-GROUP name="Device Tabs">
<MENU-ITEM name = "Add View" action_command="AddView">
<MENU-ITEM name = "Remove View" action_command="RemoveCv">
To create custom tab panel and add it in the Device Snapshot View
You need to write a custom tab panel class extending com.adventnet.nms.mapui.AbstractNmsTabPanel class. The sample code is given below.
Sample code for custom tab panel class:
public class ExampleTab extends AbstractNmsTabPanel
public void init(JApplet applet)
add(new JLabel(“USER PANEL”));
public void startTab(Properties prop)
Compile the custom tab panel class and place the class in the Client class path.
Make an entry for custom tab panel class in the DeviceTabPanels.conf file to integrate the tab panel in Web NMS. The conf file is available in the <Web NMS Home>/conf directory.
This configuration file will be read at the startup of the client and the custom tab panel classes will be loaded.
<TABPANEL PANEL-KEY="MyPanel" className="example.ExampleTab"></TABPANEL>
Integrating the Custom, Events, Alerts tab panels to the default maps:
The tab panels to be added for the map is based on the panel-keys specified in the map property tabPanels.
You can modify the map filter to add the tab panel keys of the custom tab panels, which needs to be added as tabs along with the map. You can also modify the map filter to add the default tab panels (i.e., Alerts and Events views). Panel keys should be separated by a comma and the key is case sensitive.
Add/modify the map property tabPanels which takes the tab PANEL-KEYs for custom tab panels and the module names for the default tab panels as value.
Sample Entries in the Map Filter:
Modify the Map Filter as given below to add a custom tab panel to the Map.
// This adds the panel keys of the tab panels that has to be added with the map.
Properties tabprop=new Properties();
//This specifies the table columns and the criteria for the Event CustomView
Properties properties1 = new Properties();
properties1.put("FieldsWanted", "Source=entity;Status=severity");//table columns.
properties1.put("Source","a*");//criteria sets that only the entity starts with 'a' should be shown.
//This is the new api that adds the Map with Tabs.
To add Events, Alerts tabs from the client in the Device Snapshot View
Default custom view tab panels (Alerts and Events views) can also be added to the map from the Client provided the DEVICE-VIEW parameter is set to true in the serverparameters.conf file (Application/Applet/Web-Start Client).
The procedure is given below:
Using Custom View Menu
After adding map without tab view, by invoking Custom View menu:
Select the Custom Views > Device Tabs > Add View menu item in the Application Client. Add/Modify View form will appear.
Select Alerts or Events from the drop down list for the tabpanels property. Fill the mandatory properties with valid values and optional properties as per your requirement. The properties are same as for creating Events/Alerts custom View.
Click Add View button.
To add device view to the custom maps
For the custom maps you can add the device tab views by providing the map property tabPanels in the maps.conf file present under <Web NMS Home>/conf directory as follows:
<map mapname="Failed_Objects_Map.netmap" tabPanels=”Events,Alerts,MyPanel” ...>
Using Map Properties form
While adding a new map using custom view menu:
Select the Custom Views > Add New Map menu item in the Application Client. Map Properties form will appear.
Apart from filling the mandatory properties, fill the tabPanels property to add the device tab panels with the map.
Click Add button.
After adding map without tab view, by modify the map property:
Double click on the map or select the map and click the Properties tool bar icon in the Application Client. Map Properties form will appear.
Fill the tabPanels property with the module names of the default tab panels.
Click Modify button.
Using the above procedure, you can also add the custom tab panels to the map by filling the tab panel keys in the map property form. Ensure that you have kept the compiled custom tab panel class in the client class path and configured the panel in the DeviceTabPanels.conf file.