source: issm/trunk-jpl/src/m/classes/debug.js

Last change on this file was 20777, checked in by Eric.Larour, 9 years ago

CHG (JS): massive debug of the javascript runs.

File size: 895 bytes
RevLine 
[19753]1//DEBUG class definition
2//
3// Usage:
4// debug=new debug();
5
6function debug (){
7 //methods
8 this.setdefaultparameters = function(){// {{{
9 }// }}}
[19791]10 this.classname= function(){// {{{
11 return "debug";
12 }// }}}
[19753]13 this.disp= function(){// {{{
14 console.log(sprintf(' debug parameters:'));
15 console.log(sprintf(' debug parameters:'));
16
17 fielddisplay(this,'valgrind','use Valgrind to debug (0 or 1)');
18 fielddisplay(this,'gprof','use gnu-profiler to find out where the time is spent');
19 fielddisplay(this,'profiling','enables profiling (memory, flops, time)');
20
21 }// }}}
[20777]22 this.marshall=function(md,prefix,fid) { //{{{
[20690]23 WriteData(fid,prefix,'object',this,'fieldname','profiling','format','Boolean');
[19791]24 }//}}}
[19860]25 this.fix=function() { //{{{
26 }//}}}
27
[19753]28 //properties
29 // {{{
30 this.valgrind = false;
31 this.gprof = false;
32 this.profiling = false;
33 this.setdefaultparameters();
34 //}}}
35}
Note: See TracBrowser for help on using the repository browser.