Scippy

UG

Ubiquity Generator framework

ParaParamBool Class Reference

class ParaParamBool More...

#include <paraParamSet.h>

Inheritance diagram for ParaParamBool:
ParaParam

Public Member Functions

 ParaParamBool (const char *name, const char *inComment, bool value)
 constructor More...
 
 ~ParaParamBool ()
 destructor More...
 
int getType () const
 get parameter type value More...
 
bool getDefaultValue () const
 get default parameter value More...
 
bool getValue () const
 get current parameter value More...
 
void setDefaultValue ()
 set default parameter value More...
 
void setValue (bool value)
 set parameter value More...
 
bool isDefaultValue () const
 check if current value is default value or not More...
 
- Public Member Functions inherited from ParaParam
 ParaParam (const char *inParamName, const char *inComment)
 constructor More...
 
virtual ~ParaParam ()
 destructor More...
 
const char * getParamName () const
 getter of parameter name More...
 
const char * getComment () const
 getter of comments string More...
 
virtual int getType () const =0
 get parameter type More...
 

Private Attributes

const bool defaultValue
 default bool parameter value More...
 
bool currentValue
 current bool parameter value More...
 

Detailed Description

class ParaParamBool

Definition at line 200 of file paraParamSet.h.

Constructor & Destructor Documentation

◆ ParaParamBool()

ParaParamBool ( const char *  name,
const char *  inComment,
bool  value 
)

constructor

Parameters
nameparameter name
inCommentcomments string of this parameter
valuedefault bool value of this parameter

Definition at line 210 of file paraParamSet.h.

◆ ~ParaParamBool()

destructor

Definition at line 224 of file paraParamSet.h.

Member Function Documentation

◆ getDefaultValue()

bool getDefaultValue ( ) const

get default parameter value

Returns
default parameter value

Definition at line 243 of file paraParamSet.h.

References ParaParamBool::defaultValue.

Referenced by ParaParamSet::getBoolParamDefaultValue().

◆ getType()

int getType ( ) const
virtual

get parameter type value

Returns
1: Bool

Implements ParaParam.

Definition at line 233 of file paraParamSet.h.

References UG::ParaParamTypeBool.

◆ getValue()

bool getValue ( ) const

get current parameter value

Returns
current parameter value

Definition at line 253 of file paraParamSet.h.

References ParaParamBool::currentValue.

Referenced by ParaParamSetMpi::createDiffParams(), ParaParamSet::getBoolParamValue(), and ParaParamSet::write().

◆ isDefaultValue()

bool isDefaultValue ( ) const

check if current value is default value or not

Returns
true if current value is default value

Definition at line 282 of file paraParamSet.h.

References ParaParamBool::currentValue, and ParaParamBool::defaultValue.

Referenced by ParaParamSetMpi::createDiffParams(), ParaParamSet::isBoolParamDefaultValue(), and ParaParamSet::write().

◆ setDefaultValue()

void setDefaultValue ( )

set default parameter value

Definition at line 262 of file paraParamSet.h.

References ParaParamBool::currentValue, and ParaParamBool::defaultValue.

Referenced by ParaParamSet::setBoolParamDefaultValue().

◆ setValue()

void setValue ( bool  value)

set parameter value

Parameters
valuevalue to be set

Definition at line 271 of file paraParamSet.h.

References ParaParamBool::currentValue.

Referenced by ParaParamSet::paramParaseBool(), ParaParamSet::setBoolParamValue(), and ParaParamSetMpi::setDiffParams().

Member Data Documentation

◆ currentValue

bool currentValue
private

◆ defaultValue

const bool defaultValue
private

default bool parameter value

Definition at line 202 of file paraParamSet.h.

Referenced by ParaParamBool::getDefaultValue(), ParaParamBool::isDefaultValue(), and ParaParamBool::setDefaultValue().