File "src/luacov/stats.lua
"
Manages the file with statistics (being) collected. In general the module requires that its property stats.statsfile
has been set to the filename of the statsfile to create, load, etc.
Functions
M.load () | Loads the stats file. |
M.save (data, stats) | Saves data to the statfile |
M.start () | Opens the statfile |
M.stop (stats) | Closes the statfile |
Functions
- M.load ()
-
Loads the stats file.
Return values:
- table with data
- hitcount of the line with the most hits (to provide the widest number format for reporting)
- M.save (data, stats)
-
Saves data to the statfile
Parameters:
-
data
: data to store -
stats
: filehandle where to store
-
- M.start ()
-
Opens the statfile
Return value:
filehandle - M.stop (stats)
-
Closes the statfile
Parameters:
-
stats
: filehandle to the statsfile
-