13 #include "generalmod.h" 30 enum State { Error, InCol, EndCol, EndRow };
32 virtual State add(
char) = 0;
33 const char*
getCol()
const {
return col_.buf(); }
34 const char*
errMsg()
const {
return col_.buf(); }
37 virtual void newCol() { col_.setEmpty(); colpos_ = 0;}
39 char readNewChar()
const;
63 virtual void finish();
65 static bool isNumber(
const char*);
86 : Executor(
"Data import")
87 , imphndlr_(i), exphndlr_(o)
88 , rowsdone_(0), selcolnr_(-1), atend_(false)
89 , msg_(tr(
"Importing")) {}
94 virtual int nextStep();
105 { manipulators_.erase(); addManipulator(m); }
107 { manipulators_ += m; }
#define mExpClass(module)
Definition: commondefs.h:157
const char * errMsg() const
Definition: tableconv.h:34
od_istream & strm_
Definition: tableconv.h:44
const char * getCol() const
Definition: tableconv.h:33
ExportHandler & exphndlr_
Definition: tableconv.h:112
BufferString prepend_
Before first record. Add newline if needed.
Definition: tableconv.h:67
Converter(ImportHandler &i, ExportHandler &o)
Definition: tableconv.h:85
OD class for stream write common access to the user log file, or std::cout in batch progs...
Definition: od_ostream.h:25
BufferString append_
After last record.
Definition: tableconv.h:69
int colpos_
Definition: tableconv.h:46
ImportHandler(od_istream &strm)
Definition: tableconv.h:25
#define mODTextTranslationClass(clss)
Definition: uistring.h:37
#define od_int64
Definition: plftypes.h:34
virtual void newRow()
Definition: tableconv.h:36
void setManipulator(const RowManipulator *m)
Definition: tableconv.h:104
Definition: uistring.h:88
bool isEmpty() const
Definition: odset.h:43
Set of BufferString objects.
Definition: bufstringset.h:25
bool atend_
Definition: tableconv.h:119
int rowsdone_
Definition: tableconv.h:118
OD class for stream read.
Definition: od_istream.h:23
Definition: tableconv.h:82
Set of pointers to objects.
Definition: commontypes.h:28
uiString nrDoneText() const
Definition: tableconv.h:96
ExportHandler(od_ostream &strm)
Definition: tableconv.h:56
Definition: geom2dascio.h:18
od_ostream & strm_
Definition: tableconv.h:74
Definition: tableconv.h:99
virtual ~ImportHandler()
Definition: tableconv.h:28
int colnr_
Definition: tableconv.h:116
ImportHandler & imphndlr_
Definition: tableconv.h:111
virtual ~ExportHandler()
Definition: tableconv.h:58
void addManipulator(const RowManipulator *m)
Definition: tableconv.h:106
bool isPresent(const T &) const
Definition: typeset.h:336
virtual void newCol()
Definition: tableconv.h:37
TypeSet< int > selcols_
Definition: tableconv.h:91
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:38
uiString message() const
Definition: tableconv.h:95
BufferString col_
Definition: tableconv.h:45
ObjectSet< const RowManipulator > manipulators_
Definition: tableconv.h:114
BufferStringSet row_
Definition: tableconv.h:113
od_int64 nrDone() const
Definition: tableconv.h:97
Definition: tableconv.h:53
Definition: tableconv.h:22
int selcolnr_
Definition: tableconv.h:117
bool colSel() const
Definition: tableconv.h:122
State
Definition: tableconv.h:30
Specification to enable chunkwise execution of a process.
Definition: executor.h:38
uiString msg_
Definition: tableconv.h:92