NetDataOverviewDocument
LoadDocument
NetDataOverviewTable
PingDocument
ThroughputDocument
LoadTable
PingTable
ThroughputTable
PingData
NetDataDescriptor
ColorMap
ColorScale
RGB
Extrema
RepeatWrite
The top control frame top_control.html
contains a number
JavaScript methods which can be used to load dynamically one of the
network status tables into the body frame data_body.html
.
The last file contains a HTML header but no content: its only function
is to represent the body frame.
The HTML pages with the network status tables are written by JavaScript class instances. Each class has its own private methods and variables, however all these class instances are implementing the following two methods:
write()
Write the HTML document in the body frame.plot()
Make a two-dimensional plot of the data in a new window. This is
performed by the
NetData
Applet which
is also responsible for reading the data from the Web server and for
the local storage of the data.The following classes are available:
NetDataOverviewDocument
LoadDocument
PingDocument
This class writes the HTML page containing the table with the
roundtrip data as a function of the time. The data are displayed
for all connection from a host specified by the user to all other
hosts.ThroughputDocument
This class writes the HTML page containing the table with the
throughput data as a function of the time. The data are displayed
for all connection from a host specified by the user to all other
hosts.Other important classes, from which there exist global instances in the JavaScript code, are:
NetDataDescriptor
This class contains the descriptors, describing the various data
types.ColorMap
RepeatWrite
Computer Code
font. Variable references to these
objects are written in
Variable Computer Code
font.var
.function ( |
string s,
Class c,
var v) |
// globalFunction |
NetDataOverviewDocument
This class writes the HTML page containing the overview tables with all data at a certain timestap. It is also possible to represent the data with one, compact table.
NetDataOverviewDocument ()
write ( |
var date_ind,
var need_plot) |
||
|
var |
date_ind |
The index of the timestamp of the overview. The most recent timestamp has the largest index. However, the table is displayed from the current timestamp into the history. | |||
var |
need_plot |
If true plot the data when the data window is
shown; otherwise do not plot. |
This method writes the HTML page. The table information is written
by a new, local instance of the
NetDataOverviewTable
class.
writeNewForm (var date_ind) |
|
// writeNewFormNetDataOverviewDocument |
var |
date_ind |
The index of the timestamp of the overview. |
This method writes the HTML page and switches from the long form with more tables to the compact form with one table or reverse.
plot () // plotLoadData
This method is defined in the
LoadDocument
class. It is
described there.
LoadDocument
This class writes the HTML page, containing the table with the load data as function of the time. The timestamps are going back in history.
LoadDocument ()
write ( |
var date_ind,
var need_plot) |
// writeLoadDocument |
var |
date_ind |
The index of the the most recent timestamp in the load table. | |||
var |
need_plot |
If true plot the data when the data window is
shown; otherwise do not plot. |
LoadTable
class.
plot ( |
var date_ind,
var force) |
// plotLoadData |
var |
date_ind |
The index of the timestamp from the load data. | |||
var |
force |
true : always plot the load data;
false : only plot the data when a plot window was
already shown. |
Plot the current load data. Start at the specified timestamp and precede in history.
PingDocument
This class writes the HTML page, containing table with the roundtrip values as a function of the time. The timestamps are referring back to history. The data are displayed from a host, specified by the user, to all other hsosts.
PingDocument ()
write ( |
var date_ind,
var need_plot) |
// writePingDocument |
var |
date_ind |
The index of the most recent timestamp in the table with roundtrip data. | |||
var |
need_plot |
If true plot the data when the data window is
shown; otherwise do not plot. |
This method writes the HTML page. The table itself is written by a
new, local instance of the
PingTable
class.
writeNewHost ( |
var date_ind,
var index_ping_host) |
||
|
var |
date_ind |
The index of the most recent timestamp in the table. | |||
var |
index_ping_host |
The index of the host from which all roundtrip connection data are shown. |
This method also writes the HTML page. However, a new host is introduced for which the data from the connections with all other hosts are shown.
writeNewPingType ( |
var date_ind,
var new_ping_type) |
|||
|
var |
date_ind |
The index of the most recent timestamp in the table. | |||
var |
new_ping_type |
The index of the ping type ([0, 3]) for which the roundtrip data are displayed. |
This method also writes the HTML page, but for a new ping type from the set: { min, avg, max, all }. The set index ([0, 3]) corresponds with the ping type index to specify.
plot ( |
var date_ind,
var force) |
// plotPingData |
var |
date_ind |
The index of the timestamp from the most recent roundtrip data in the plot. | |||
var |
force |
true : always plot the roundtrip data;
false : only plot the data when a plot window was
already shown. |
Plot the current roundtrip data. Start at the specified timestamp and precede in history.
ThroughputDocument
This class writes the HTML page, containing table with the throughput values as a function of the time. The timestamps are referring back to history. The data are displayed from a host, specified by the user, to all other hsosts.
ThroughputDocument ()
write ( |
var date_ind,
var need_plot) |
// writeThroughputDocument |
var |
date_ind |
The index of the most recent timestamp in the table with throughput data. | |||
var |
need_plot |
If true plot the data when the data window is
shown; otherwise do not plot. |
ThroughputTable
class.
writeNewHost ( |
var date_ind,
var index_throughput_host) |
||
|
var |
date_ind |
The index of the most recent timestamp in the table. | |||
var |
index_throughput_host |
The index of the host from which all throughput connection data are shown. |
This method also writes the HTML page. However, a new host is introduced for which the data from the connections with all other hosts are shown.
plot ( |
var date_ind,
var force) |
// plotThroughputData |
var |
date_ind |
The index of the timestamp from the most recent throughput data in the plot. | |||
var |
force |
true : always plot the throuhput data;
false : only plot the data when a plot window was
already shown. |
Plot the current throughput data. Start at the specified timestamp and precede in history.
NetDataOverviewTable
This class writes the overview table which contains all available network data at a certain moment.
NetDataOverviewTable ()
Extrema load_extrema
Conatins the extrema of the load values in the table. These extrema
are used at the color scaling.
Extrema ping_extrema
Contains the extream of the roundtrip values in the table.
Extrema throughput_extrema
Contains the extrema of the throughput values is the table.
writeTable (var date_ind)
// writeNetDataOverviewTable
var |
date_ind |
The index of the most recent timestamp in the table. |
Write the overview tables in the long or compact form.
Three different color scalings
(class ColorScale
) are
respectively used for the load, roundtrip and throughput values.
writeCompactTable ( |
var day,
var time,
var[] host_titles,
var nr_hosts,
var nr_conns,
var[] load_values,
PingData[] atm_ping_data,
PingData[] inet_ping_data,
var[] atm_throughput_values,
var[] inet_throughput_values) |
||
|
var |
day |
The day of the overview. | |||
var |
time |
The time of the overview. | |||
var[] |
host_titles |
The array with host titles. | |||
var |
nr_hosts |
The # hosts in the overview. | |||
var |
nr_conns |
The # connections bewteen the hosts. | |||
var[] |
load_values |
The array with load values. | |||
PingData[] |
atm_ping_data |
The array with ATM ping data. | |||
PingData[] |
inet_ping_data |
The array with Internet ping data. | |||
var[] |
atm_throughput_values |
The array with ATM throughput values. | |||
var[] |
inet_throughput_values |
The array with Internet throughput values. |
Write the overview table in the compact form. The table has the following form:
ColorScale
) are
respectively used for the load, roundtrip and throughput values.
writeLoadTable ( |
var day,
var time,
var[] host_titles,
var nr_hosts,
var[] load_values) |
||
|
var |
day |
The day of the overview. | |||
var |
time |
The time of the overview. | |||
var[] |
host_titles |
The array with host titles. | |||
var |
nr_hosts |
The # hosts in the overview. | |||
var[] |
load_values |
The array with load values. |
Write the load table as part of the long form.
writePingTable ( |
var day,
var time,
var[] host_titles,
var nr_hosts,
var nr_conns,
PingData[] atm_ping_data,
PingData[] inet_ping_data) |
||
|
var |
day |
The day of the overview. | |||
var |
time |
The time of the overview. | |||
var[] |
host_titles |
The array with host titles. | |||
var |
nr_hosts |
The # hosts in the overview. | |||
var |
nr_conns |
The # connections bewteen the hosts. | |||
PingData[] |
atm_ping_data |
The array with ATM ping data. | |||
PingData[] |
inet_ping_data |
The array with Internet ping data. |
Write the roundtrip table as part of the long form.
writeThroughputTable ( |
var day,
var time,
var[] host_titles,
var nr_hosts,
var nr_conns,
var[] atm_throughput_values,
var[] inet_throughput_values) |
||
|
var |
day |
The day of the overview. | |||
var |
time |
The time of the overview. | |||
var[] |
host_titles |
The array with host titles. | |||
var |
nr_hosts |
The # hosts in the overview. | |||
var |
nr_conns |
The # connections bewteen the hosts. | |||
var[] |
atm_throughput_values |
The array with ATM throughput values. | |||
var[] |
inet_throughput_values |
The array with Internet throughput values. |
Write the throughput table as part of the long form.
writeColorTable ()
// writeOverviewColorTable
]
Write the table with the three color scalings used.
LoadTable
This class writes the table with the load data as a function of the time.
LoadTable ()
Extrema extrema
writeTable (var date_ind)
// writeLoadTable
var |
date_ind |
The index of the most recent timestamp in the table. |
This class writes the load table.
setExtrema ( |
var[][] load_values,
var nr_hosts) |
// setLoadExtrema |
var[][] |
load_values |
The double indexed array with the load values for all hosts. The first index describes the hosts and the second index the dates. | |||
var |
nr_hosts |
De # hosts. |
Determine the extrema for all load data in the table and store these
extrema in the class varable extrema
writeColorTable ()
// writeLoadColorTable
Write the table with the used color scaling.
PingTable
This class writes the table with roundtrip data as a function of the time. Only the roundtrip data for all connections with a host, specified by the user, are shown.
PingTable ()
Extrema extrema
writeTable (var date_ind)
// writePingTable
var |
date_ind |
The index of the most recent timestamp in the table. |
This method writes the roundtrip table.
setExtrema ( |
PingData[][] ping_data,
var nr_hosts,
var index_ping_host) |
||
|
PingData[][] |
ping_data |
The double indexed array with the ping data for all hosts. The first index describes the hosts and the second index the dates. | |||
var |
nr_hosts |
De # hosts. | |||
var |
index_ping_host |
The ping data for all the connections with this host are shown. |
Determine the extrema for all ping data of the specified type in the
table and store these extrema in the class varable
extrema
.
writeColorTable ()
// writePingColorTable
Write the table with the used color scaling.
ThroughputTable
This class writes the table with throughput data as a function of the time. Only the throughput data for all connections with a host, specified by the user, are shown.
ThroughputTable ()
Extrema extrema
writeTable (var date_ind)
// writeThroughputTable
var |
date_ind |
The index of the most recent timestamp in the table. |
This class writes the throughput table.
setExtrema ( |
var[][] throughput_values,
var nr_hosts,
var index_throughput_host) |
||
|
var[][] |
throughput_values |
The double indexed array with the throughput values for all hosts. The first index describes the hosts and the second index the dates. | |||
var |
nr_hosts |
De # hosts. | |||
var |
index_throughput_host |
The throughput values for all the connections with this host are shown. |
Determine the extrema for all throughput values in the table and
store these extrema in the class varable
extrema
.
writeColorTable ()
// writeThroughputColorTable
Write the table with the used color scaling.
PingData
This class implements the data type used for the various type of roundtrip data. It is possible to display the minimum, average, maximum or all three data types.
PingData (var nr_data)
var |
nr_data |
Specify the # ping data to be stored in this class. |
var[] values
This is the array with numerical ping values from a specified type.
These values are typical used in the color scaling.
var[] strings
This is the array with the string representation of the ping data
from a specified type. These strings are typical used for printing.
parse ( |
var i,
var j,
var value_ind,
var date_ind,
var ping_type,
var net_type) |
// parsePing |
var |
i |
The index of the 1th host used to get the ping value. | |||
var |
j |
The index of the 2th host used to get the ping value. | |||
var |
value_ind |
The index where the ping value and its string representation must be stored. | |||
var |
date_ind |
The index of the date at the
NetData Applet
which ping value must be obtained. |
|||
var |
ping_type |
The type of the ping value. | |||
var |
net_type |
The index of the net traffic type. |
Obtain a ping value with the specified type from the
NetData
Applet. It
is returned by the Applet as a string. It is stored both as a float
and as a string in the corresponding data arrays values
and strings
.
writeColumn ( |
ColorScale color_scale,
RGB rgb_scale,
var index,
var td_flags,
var value_type) |
||
|
ColorScale |
color_scale |
The color scaling used for the ping values. | |||
RGB |
rgb_scale |
The RGB scale values. | |||
var |
index |
The index of the ping value and string representation. | |||
var |
td_flags |
Flags used in the <TD> HTML element. |
|||
var |
value_type |
The value type of the net traffic. |
Write a ping column value.
NetDataDescriptor
This class contains the descriptors, describing the various net data types. The types are described by member variables which can be accessed to obtain the data for a specific net data type. Each net data type is represented by a global variable in an array. The current index is stored in another global variable.
NetDataDescriptor ( |
var time_or_date_id_title,
var time_or_date_id_prefix,
var table_date_step,
var table_min_select_index,
var select_title) |
var |
time_or_date_id_title |
The title which characterises the used time or date ID. | |||
var |
time_or_date_id_prefix |
The prefix to be placed before the time or date ID. May be an empty string. | |||
var |
table_date_step |
The date time step to be used in the net data tables. | |||
var |
table_min_select_index |
The index to be used in the time interval selector for the net data table. | |||
var |
select_title |
The title to be used in the date selector window. When this variable is an empty string no date selector window is used. |
Initialse the class variables with the specified values.
The class instances are already described in the Constructor: they have the same names and functionalities as the Constructor arguments.
ColorMap
This class defines the color table which is used at the color scaling.
ColorMap ()
var max_color
The maximum value of a RGB intensity.
RGB[] color_table
The array with RGB values which is used to interpolate an intensity
to a color.
writeTable ( |
string title,
Extrema extrema,
var nr_color_rows,
var scale_factor) |
||
|
string |
load_values |
The title of the data whose color scaling is shown. | |||
Extrema |
extrema |
De extrema of the data. | |||
var |
nr_color_rows |
The # color rows in the table. | |||
var |
scale_factor |
The factor used to scale the gauage values such that they can be displayed in the table rounded. |
Write the color table in the frame body of a data series.
openTable () // openColorMapTable
Open the scaling table.
writeRow ( |
string title,
Extrema extrema,
var nr_color_rows,
var scale_factor) |
||
|
string |
load_values |
The title of the data whose color scaling is show. | |||
Extrema |
extrema |
De extrema of the data. | |||
var |
nr_color_rows |
The # color rows in the table. | |||
var |
scale_factor |
The factor used to scale the gauage values such that they can be displayed in the table rounded. |
Write a row in the color table.
closeTable () // closeColorMapTable
Close the color table.
ColorScale
This class is used at the color scaling of an intensity.
ColorScale (Extrema extrema)
Extrema |
extrema |
The extrema of the data which are used to initialize this class instance to scale these data. |
var scale_min
The minimum of the data.
var scale_max
The maximum of the data.
ColorMap color_map
The colormap which is used to determine the interpolation at the
data scaling.
scaleRGB ( |
RGB rgb_scale,
var val) |
// scaleRGB |
RGB |
rgb_scale |
The RGB value which will contain the scaled RGB intensities of the corresponding value. | |||
var |
val |
The value from which the color scaling should be determined. |
Determine the color scaling of a specified value.
RGB
This class defines a RGB value.
RGB ( |
var red,
var green,
var blue) |
var |
red |
The red component which is used to initialize the class instance. | |||
var |
green |
The green component. | |||
var |
blue |
The blue component. |
var red
The red component.
var green
The green component.
var blue
The blue component.
toColorString () // RGBToColorString
Convert the stored RGB value to a HTML color string.
Extrema
This class contains the extrema of a data series.
Extrema ()
The extrema of a new class instance are default set to null and undefined.
var min
The minimum value.
var max
The maximum value.
var defined
A boolean flag which contains the defined state of a class instance.
After creation the state is always undefined.
set ( |
var[] values,
var nr_values) |
// setExtrema |
var[] |
values |
The values from which the extrema should be determined. | |||
var |
nr_values |
The maximum # values which should be used for the determination of the extrema. There will be started at the first array element. All values will be evaluated when this value is zero. |
Determine the extrema of an array and put them in this class instance.
RepeatWrite
This periodically writes the current HTML page. The current page
description is stored in a global variable. The writing is performed by
calling the write()
method of this variable. The system
function setTimeout()
is used for the periodic display.
This method calls a function after a timeout period without blocking the
browser during this period.
RepeatWrite ()
var time_out
The timeout time [ms].
var timer_set
Boolean flag which contains the state of displaying periodically. At
initialisation no periodic display is performed.
var timer_id
ID, returned by setTimeout()
. It is required to stop
the timer.
NetDataDocument current_document
The class instance of the current document from which the
write()
will be called to redisplay the current
document.
set (var set_on) // setRepeatWrite
var |
set_on |
Boolean flag which specifies if the periodic display should be switched on or off. |
Switch on or off the periodic displaying. Default the periodic displaying is off.
The other class methods this.repeat()
and
this.clear()
are only internally used.
Therefore, they are not treated here.