1.4.1
CCC
 
OptDbg Class Reference

#include <OptDbg.hpp>

Detailed Description

Operate the list of active Debug options These options correspond to various keywords chosen from a close list (see EDbg.hpp). When one of these options is switched ON, some statements are printed each time this particular option is concerned

As example, to produce specific output during all Kriging steps, you should use;

OptCst::define(EDbg::KRIGING)

To cancel this option, it suffices to use:

OptCst::undefine(EDbg::KRIGING)

To know the current status of all these environmental parameters, use the display() function.

A complementary option is to use the Reference: this is an index such that, when the rank of the target matches this number, all the flags are turned ON automatically. This Reference index is provided as a 1-based number.

Static Public Member Functions

static void reset ()
 
static bool queryByKey (const String &name)
 
static void defineByKey (const String &name)
 
static void undefineByKey (const String &name)
 
static bool query (const EDbg &option, bool discardForce=false)
 
static void define (const EDbg &option)
 
static void undefine (const EDbg &option)
 
static void defineAll ()
 
static void undefineAll ()
 
static void display ()
 
static void setCurrentIndex (int cur_index)
 
static bool isReferenceDefined ()
 
static void setReference (int index)
 
static int getReference ()
 
static bool force ()
 
static int getCurrentIndex ()
 

Member Function Documentation

◆ define()

void OptDbg::define ( const EDbg &  option)
static

Switching ON a option

Parameters
optionDescription of the option (Keyword)

◆ defineAll()

void OptDbg::defineAll ( void  )
static

◆ defineByKey()

void OptDbg::defineByKey ( const String name)
static

Switching ON a option

Parameters
nameDescription of the option (Name)

◆ display()

void OptDbg::display ( void  )
static

◆ force()

bool OptDbg::force ( void  )
static

◆ getCurrentIndex()

static int OptDbg::getCurrentIndex ( )
inlinestatic

◆ getReference()

static int OptDbg::getReference ( )
inlinestatic

◆ isReferenceDefined()

static bool OptDbg::isReferenceDefined ( )
inlinestatic

◆ query()

bool OptDbg::query ( const EDbg &  option,
bool  discardForce = false 
)
static

Check if a DEBUG option has been switched ON or NOT

Parameters
optionType of the option to be searched for
discardForceWhen TRUE, does not consider the "forcing" option (see remarks)
Remarks
The use of gstlearn enables the user to FORCE the switch ON of one or several debugging options. This is the case for example when you want to trace the processing of a specific target (defined using setReference). When this option is switched OFF, this specific case is not taken into account
Returns
TRUE if the option is switch ON, FALSE otherwise

◆ queryByKey()

bool OptDbg::queryByKey ( const String name)
static

◆ reset()

void OptDbg::reset ( )
static

◆ setCurrentIndex()

static void OptDbg::setCurrentIndex ( int  cur_index)
inlinestatic

◆ setReference()

static void OptDbg::setReference ( int  index)
inlinestatic

◆ undefine()

void OptDbg::undefine ( const EDbg &  option)
static

Switching OFF an option

Parameters
optionDescription of the Option (Keyword)

◆ undefineAll()

void OptDbg::undefineAll ( void  )
static

◆ undefineByKey()

void OptDbg::undefineByKey ( const String name)
static

Switching OFF a option

Parameters
nameDescription of the option (Name)

The documentation for this class was generated from the following files: