Action #818

Feature #692: Perform an extensive interface review of all classes

Add chatter level to print() methods

Added by Knödlseder Jürgen about 11 years ago. Updated over 10 years ago.

Status:ClosedStart date:01/12/2013
Priority:NormalDue date:
Assigned To:Knödlseder Jürgen% Done:

100%

Category:-Estimated time:0.00 hour
Target version:00-08-00
Duration:

Description

To insure a homogenous use of printing throughout GammaLib, an integer argument named chatter shall be added to all print() methods that instruct the method about the level of information that is requested. The following chattiness shall be implemented:
  • chatter=0: no information is printed, except of errors
  • chatter=1: Level terse. Only summary information is printed.
  • chatter=2: Level normal. Normal level of information, useful for understanding the class content.
  • chatter=3: Level explicit. Detailed information, useful for understanding the inner workings of the classes.
  • chatter=4: Level verbose. Produces the maximum information, useful for debugging.

chatter=2 is the default level that shall be taken if no argument is passed.

A homogenous implementation of the chatter levels should be aimed for among all classes.

The GLog class shall have a m_chatter member that sets the default chattiness for the logger. In that way, the logger can control the chattiness of the class output, providing a homogenous information handling in GammaLib applications.


Recurrence

No recurrence.

History

#1 Updated by Knödlseder Jürgen about 11 years ago

  • Description updated (diff)

#2 Updated by Knödlseder Jürgen about 11 years ago

  • Status changed from New to In Progress

#3 Updated by Knödlseder Jürgen about 11 years ago

  • Assigned To set to Knödlseder Jürgen

#4 Updated by Knödlseder Jürgen about 11 years ago

  • % Done changed from 0 to 80

A GChatter enumerator has been defined in the new GTypemaps.hpp file:

typedef enum {
    SILENT = 0,
    TERSE = 1,
    NORMAL = 2,
    EXPLICIT = 3,
    VERBOSE = 4
} GChatter;

This enumerator is not used as argument in all print() method. This paths the way to implement chatter control in the GLog class.

#5 Updated by Knödlseder Jürgen about 11 years ago

  • Status changed from In Progress to Feedback
  • % Done changed from 80 to 100
  • Remaining (hours) set to 0.0

Chatter control has now been implemented in GLog and GApplication. The feature is considered as closed, although implementation of different chatter levels in most of the print() methods still needs to be done. But the infrastructure is now there ...

#6 Updated by Knödlseder Jürgen over 10 years ago

  • Status changed from Feedback to Closed
  • Estimated time set to 0.00

Also available in: Atom PDF