28 #ifndef DOXYGEN_SHOULD_SKIP_THIS 36 template <
template <
typename >
class ALLOC >
37 DBInitializerFromCSV< ALLOC >::DBInitializerFromCSV(
38 const std::string filename,
39 bool fileContainsNames,
40 const std::string delimiter,
41 const char commentmarker,
42 const char quoteMarker,
43 const typename DBInitializerFromCSV< ALLOC >::allocator_type& alloc) :
44 IDBInitializer< ALLOC >(IDBInitializer< ALLOC >::InputType::STRING, alloc),
45 _filename_(filename), _delimiter_(delimiter), _comment_marker_(commentmarker),
46 _quote_marker_(quoteMarker), _first_row_has_names_(fileContainsNames),
47 _input_stream_(_filename_, std::ifstream::in),
48 _parser_(_input_stream_, delimiter, commentmarker, quoteMarker), _var_names_(alloc) {
50 if ((_input_stream_.rdstate() & std::ifstream::failbit) != 0) {
51 GUM_ERROR(IOError,
"File " << filename <<
" not found")
55 if (fileContainsNames) {
57 _var_names_ = _parser_.current();
60 GUM_CONSTRUCTOR(DBInitializerFromCSV);
65 template <
template <
typename >
class ALLOC >
77 template <
template <
typename >
class ALLOC >
82 template <
template <
typename >
class ALLOC >
95 template <
template <
typename >
class ALLOC >
101 template <
template <
typename >
class ALLOC >
118 template <
template <
typename >
class ALLOC >
125 template <
template <
typename >
class ALLOC >
132 template <
template <
typename >
class ALLOC >
167 template <
template <
typename >
class ALLOC >
175 template <
template <
typename >
class ALLOC >
183 template <
template <
typename >
class ALLOC >
191 template <
template <
typename >
class ALLOC >
INLINE void emplace(Args &&... args)
Database(const std::string &filename, const BayesNet< GUM_SCALAR > &bn, const std::vector< std::string > &missing_symbols)