glucat  0.12.0
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | Friends | List of all members
glucat::control_t Class Reference

Parameters to control tests. More...

#include <control.h>

Public Member Functions

int call (intfn f) const
 Call a function that returns int. More...
 
int call (intintfn f, int arg) const
 Call a function of int that returns int. More...
 

Static Public Member Functions

static const control_tcontrol (int argc, char **argv)
 
static bool verbose ()
 Produce more detailed output from tests. More...
 

Private Member Functions

bool valid () const
 
bool catch_exceptions () const
 
 control_t (int argc, char **argv)
 Constructor from program arguments. More...
 
 control_t ()=default
 
 ~control_t ()=default
 
 control_t (const control_t &)=delete
 
control_toperator= (const control_t &)=delete
 

Private Attributes

bool m_valid
 Test parameters are valid. More...
 
bool m_catch_exceptions
 Catch exceptions. More...
 

Static Private Attributes

static bool m_verbose_output = false
 Produce more detailed output from tests. More...
 

Friends

class friend_for_private_destructor
 

Detailed Description

Parameters to control tests.

Definition at line 39 of file control.h.

Constructor & Destructor Documentation

◆ control_t() [1/3]

glucat::control_t::control_t ( int  argc,
char **  argv 
)
private

Constructor from program arguments.

Test control constructor from program arguments.

Definition at line 89 of file control.h.

References GLUCAT_PACKAGE_NAME, GLUCAT_VERSION, m_catch_exceptions, m_valid, m_verbose_output, and valid().

◆ control_t() [2/3]

glucat::control_t::control_t ( )
privatedefault

◆ ~control_t()

glucat::control_t::~control_t ( )
privatedefault

◆ control_t() [3/3]

glucat::control_t::control_t ( const control_t )
privatedelete

Member Function Documentation

◆ call() [1/2]

int glucat::control_t::call ( intfn  f) const
inline

Call a function that returns int.

Definition at line 137 of file control.h.

References catch_exceptions(), glucat::try_catch(), and valid().

◆ call() [2/2]

int glucat::control_t::call ( intintfn  f,
int  arg 
) const
inline

Call a function of int that returns int.

Definition at line 151 of file control.h.

References catch_exceptions(), glucat::try_catch(), and valid().

◆ catch_exceptions()

bool glucat::control_t::catch_exceptions ( ) const
inlineprivate

Definition at line 49 of file control.h.

References m_catch_exceptions.

Referenced by call().

◆ control()

static const control_t& glucat::control_t::control ( int  argc,
char **  argv 
)
inlinestatic

Single instance Ref: Scott Meyers, "Effective C++" Second Edition, Addison-Wesley, 1998.

Definition at line 71 of file control.h.

◆ operator=()

control_t& glucat::control_t::operator= ( const control_t )
privatedelete

◆ valid()

bool glucat::control_t::valid ( ) const
inlineprivate

Definition at line 44 of file control.h.

References m_valid.

Referenced by call(), and control_t().

◆ verbose()

static bool glucat::control_t::verbose ( )
inlinestatic

Produce more detailed output from tests.

Definition at line 80 of file control.h.

References m_verbose_output.

Friends And Related Function Documentation

◆ friend_for_private_destructor

friend class friend_for_private_destructor
friend

Friend declaration to avoid compiler warning: "... only defines a private destructor and has no friends" Ref: Carlos O'Ryan, ACE http://doc.ece.uci.edu

Definition at line 67 of file control.h.

Member Data Documentation

◆ m_catch_exceptions

bool glucat::control_t::m_catch_exceptions
private

Catch exceptions.

Definition at line 48 of file control.h.

Referenced by catch_exceptions(), and control_t().

◆ m_valid

bool glucat::control_t::m_valid
private

Test parameters are valid.

Definition at line 43 of file control.h.

Referenced by control_t(), and valid().

◆ m_verbose_output

bool glucat::control_t::m_verbose_output = false
staticprivate

Produce more detailed output from tests.

Definition at line 53 of file control.h.

Referenced by control_t(), and verbose().


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