tesseract  5.0.0-alpha-619-ge9db
tesseract::IntParam Class Reference

#include <params.h>

Inheritance diagram for tesseract::IntParam:
tesseract::Param

Public Member Functions

 IntParam (int32_t value, const char *name, const char *comment, bool init, ParamsVectors *vec)
 
 ~IntParam ()
 
 operator int32_t () const
 
void operator= (int32_t value)
 
void set_value (int32_t value)
 
void ResetToDefault ()
 
void ResetFrom (const ParamsVectors *vec)
 
- Public Member Functions inherited from tesseract::Param
 ~Param ()=default
 
const char * name_str () const
 
const char * info_str () const
 
bool is_init () const
 
bool is_debug () const
 
bool constraint_ok (SetParamConstraint constraint) const
 

Additional Inherited Members

- Protected Member Functions inherited from tesseract::Param
 Param (const char *name, const char *comment, bool init)
 
- Protected Attributes inherited from tesseract::Param
const char * name_
 
const char * info_
 
bool init_
 
bool debug_
 

Detailed Description

Definition at line 152 of file params.h.

Constructor & Destructor Documentation

◆ IntParam()

tesseract::IntParam::IntParam ( int32_t  value,
const char *  name,
const char *  comment,
bool  init,
ParamsVectors vec 
)
inline

Definition at line 154 of file params.h.

154  {
155  if (strcmp(vec->int_params[i]->name_str(), name_) == 0) {
156  // printf("overriding param %s=%d by =%d\n", name_, value_,
157  // *vec->int_params[i]);
158  value_ = *vec->int_params[i];
159  break;
160  }
161  }

◆ ~IntParam()

tesseract::IntParam::~IntParam ( )
inline

Definition at line 162 of file params.h.

164 :
165  int32_t value_;

Member Function Documentation

◆ operator int32_t()

tesseract::IntParam::operator int32_t ( ) const
inline

Definition at line 163 of file params.h.

164 :
165  int32_t value_;

◆ operator=()

void tesseract::IntParam::operator= ( int32_t  value)
inline

Definition at line 164 of file params.h.

164 :
165  int32_t value_;

◆ ResetFrom()

void tesseract::IntParam::ResetFrom ( const ParamsVectors vec)
inline

Definition at line 167 of file params.h.

171  : public Param {
172  public:
173  BoolParam(bool value, const char* name, const char* comment, bool init,
174  ParamsVectors* vec)
175  : Param(name, comment, init) {
176  value_ = value;

◆ ResetToDefault()

void tesseract::IntParam::ResetToDefault ( )
inline

Definition at line 166 of file params.h.

171 : public Param {

◆ set_value()

void tesseract::IntParam::set_value ( int32_t  value)
inline

Definition at line 165 of file params.h.

171 : public Param {

The documentation for this class was generated from the following file:
tesseract::Param::Param
Param(const char *name, const char *comment, bool init)
Definition: params.h:141
tesseract::Param::name_
const char * name_
Definition: params.h:146