blob: 2063ba5665608f0061a318ab34919e6e089d225f [file] [log] [blame]
Paul Greyson7a300822013-04-09 12:57:49 -07001/***************************************************************************************************
2global variables
3***************************************************************************************************/
4
5
6/***************************************************************************************************
7the latest update to the model
8***************************************************************************************************/
9var model;
10
11/***************************************************************************************************
12cached JSON representation of the model. used to detect model changes and update the UI.
13***************************************************************************************************/
14var modelString;
15
Paul Greyson7a300822013-04-09 12:57:49 -070016/***************************************************************************************************
Paul Greysonc090d142013-04-09 16:59:03 -070017the root element for the topology view
Paul Greyson7a300822013-04-09 12:57:49 -070018***************************************************************************************************/
Paul Greysonc090d142013-04-09 16:59:03 -070019var topology;
Paul Greyson7a300822013-04-09 12:57:49 -070020
21/***************************************************************************************************
22links that were created in the webui but which have not appeared in the links API response yet
23these timeout after pendingTimeout
24***************************************************************************************************/
25var pendingLinks = {};
26
27/***************************************************************************************************
Paul Greysone15c4392013-04-09 15:05:31 -070028current links including pending
29***************************************************************************************************/
30var links;
31
32/***************************************************************************************************
33a map from srcDPID => map of dstDPID=>link
34***************************************************************************************************/
35var linkMap;
36
37/***************************************************************************************************
Paul Greyson7a300822013-04-09 12:57:49 -070038the flows that are displayed in the selected flow table
39this may include pending flows which have not appeared in the flows API response yet
40***************************************************************************************************/
41var selectedFlows = [];
42
43/***************************************************************************************************
44a mapping from controller name to color used for color coding the topology and ONOS nodes views
45***************************************************************************************************/
Paul Greysonbbd708b2013-04-09 22:37:31 -070046var controllerColorMap = {};
47
48/***************************************************************************************************
49defined by rings.js or map.js this is where the flows are drawn.
50***************************************************************************************************/
51var flowLayer;
52
53/***************************************************************************************************
54hack to make the old ring drawing code compatible with the shared flow drawing code
55will be obsoleted once the ring drawing code is disposed of
56***************************************************************************************************/
57var drawingRings;