1 The code is structured into these files:
5 String functions and other small utility functions. This is
6 included directly into virt_top.ml.
10 This is the virt-top program.
12 The two interesting functions are called 'collect' and 'redraw'.
14 'collect' collects all the information about domains, etc.
16 'redraw' updates the display on each frame.
18 Another interesting function is 'start_up' which handles all
19 start-up stuff, eg. command line arguments, connecting to the
20 hypervisor, enabling curses.
22 The function 'main_loop' runs the main loop and has sub-functions
23 to deal with keypresses, help screens and so on.
26 A generated file which adds gettext support if ocaml-gettext
27 was found at configure time, or else stubs it out.
31 Any code which needs the optional xml-light library goes
32 in here. Mainly for parsing domain XML descriptions to get
33 the list of block devices and network interfaces.
35 The reason for having it in a separate file is so that we
36 don't depend on xml-light.
40 Any code which needs the optional ocaml-csv library goes
41 in here. This implements the --csv command line option.
43 opt_calendar1.ml, opt_calendar2.ml
45 Any code which needs the optional ocaml-calendar library
46 (v1 or v2) goes in here. This implements the --end-time
51 This is just a small bit of code to glue the modules together
52 Top + Opt_xml? + Opt_csv? + Opt_calendar{1,2}?
54 The man-page is generated from the single file:
58 which generates (using perldoc) the following: