50#ifndef DOXYGEN_SHOULD_SKIP_THIS
64 DBTranslator*
create(
const Variable& var,
65 const std::vector< std::string >& missing_symbols,
66 const bool editable_dictionary,
67 std::size_t max_dico_entries) {
68 switch (var.varType()) {
70 const LabelizedVariable& xvar =
static_cast< const LabelizedVariable&
>(var);
71 return new DBTranslator4LabelizedVariable(xvar,
78 const auto& xvar =
static_cast< const IntegerVariable&
>(var);
80 return new DBTranslator4IntegerVariable(xvar, missing_symbols, max_dico_entries);
84 const auto& xvar =
static_cast< const IDiscretizedVariable&
>(var);
85 return new DBTranslator4DiscretizedVariable(xvar, missing_symbols, max_dico_entries);
89 const auto& xvar =
static_cast< const RangeVariable&
>(var);
90 return new DBTranslator4RangeVariable(xvar,
97 const auto& xvar =
static_cast< const IContinuousVariable&
>(var);
98 return new DBTranslator4ContinuousVariable(xvar, missing_symbols, editable_dictionary);
102 const auto& xvar =
static_cast< const NumericalDiscreteVariable&
>(var);
103 return new DBTranslator4NumericalDiscreteVariable(xvar,
110 "The translator for Variable "
112 <<
" cannot yet be created yet by named constructor CreatePtr.");
Utilities for DBTranslators.
Utilities for DBTranslators.
#define GUM_ERROR(type, msg)
DBTranslator * create(const Variable &var, const bool editable_dictionary=false, std::size_t max_dico_entries=std::numeric_limits< std::size_t >::max())
named constructor
include the inlined functions if necessary
gum is the global namespace for all aGrUM entities