50 for (i = 0, imax =
mList.size(); i < imax; i++)
79 for (in.get(c); c != 0x0a && c != 0x0d; in.get(c))
81 if (in.fail() || in.eof())
break;
98 if ((c == 0x0d && in.peek() == 0x0a) ||
99 (c == 0x0a && in.peek() == 0x0d))
120 for (i = 0, imax =
mList.size(); i < imax; i++)
130 for (; i < imax; i++)
147 for (i = 0, imax =
mList.size(); i < imax; i++)
149 if (Last >=
mList[i]->First)
return false;
151 Last =
mList[i]->Last;
153 if (Last >
mLines)
return false;
160 const size_t & value)
163 mList[index]->Last < value ||
164 (value ==
mList[index]->Last &&
165 value ==
mList[index]->pExperiment->getHeaderRow()))
return false;
167 size_t Saved =
mList[index]->First;
168 mList[index]->First = value;
171 mList[index]->First = Saved;
177 const size_t & value)
180 value <
mList[index]->First ||
181 (value ==
mList[index]->First &&
182 value ==
mList[index]->pExperiment->getHeaderRow()))
return false;
184 size_t Saved =
mList[index]->Last;
185 mList[index]->Last = value;
188 mList[index]->Last = Saved;
194 const size_t & value)
196 return (value <=
mLines &&
198 value <
mList[index]->First ||
199 mList[index]->Last < value));
204 std::vector< std::string > List;
208 for (i = 0, imax =
mList.size(); i < imax; i++)
209 List.push_back(
mList[i]->pExperiment->getObjectName());
218 for (i = 0, imax =
mList.size(); i < imax; i++)
219 if (
mList[i]->pExperiment->getObjectName() == name)
220 return mList[i]->pExperiment;
238 size_t i, imax =
mList.size();
240 for (i = 0; i < imax; i++)
242 if (First <
mList[i]->First)
244 Last =
mList[i]->First - 1;
250 if (
mList[i]->Last + 1 > First)
251 First =
mList[i]->Last + 1;
273 std::vector<size_t>::const_iterator it =
mEmptyLines.begin();
274 std::vector<size_t>::const_iterator end =
mEmptyLines.end();
276 while (it != end && *it < First) ++it;
281 if (it != end && *it == First)
306 pExperiment(&Experiment),
307 First(pExperiment->getFirstRow()),
308 Last(pExperiment->getLastRow())
const std::string & getFileName() const
bool getFirstUnusedSection(size_t &First, size_t &Last)
std::vector< CExperimentInfo * > mList
bool validateLast(const size_t &index, const size_t &value)
const std::string & getFileName() const
CExperiment * getExperiment(const size_t &index)
bool adjustForEmptyLines(size_t &First, size_t &Last)
std::vector< size_t > mEmptyLines
bool setFileName(const std::string &fileName)
bool getNextUnusedSection(size_t &First, size_t &Last)
bool validateFirst(const size_t &index, const size_t &value)
std::vector< std::string > getExperimentNames() const
static CLocaleString fromUtf8(const std::string &utf8)
bool validateHeader(const size_t &index, const size_t &value)
CExperiment * getExperiment(const std::string &name)
size_t getExperimentCount() const