cosmetics: list -> vector in more places
This commit is contained in:
parent
5462f639d3
commit
a17b7523e7
44 changed files with 285 additions and 313 deletions
|
@ -98,7 +98,8 @@ bool DocSequenceDb::getEnclosing(Rcl::Doc& doc, Rcl::Doc& pdoc)
|
|||
list<string> DocSequenceDb::expand(Rcl::Doc &doc)
|
||||
{
|
||||
setQuery();
|
||||
return m_q->expand(doc);
|
||||
vector<string> v = m_q->expand(doc);
|
||||
return list<string>(v.begin(), v.end());
|
||||
}
|
||||
|
||||
string DocSequenceDb::title()
|
||||
|
|
|
@ -44,10 +44,10 @@ bool RclDHistoryEntry::encode(string& value)
|
|||
// Current entry format is "U time b64udi"
|
||||
bool RclDHistoryEntry::decode(const string &value)
|
||||
{
|
||||
list<string> vall;
|
||||
vector<string> vall;
|
||||
stringToStrings(value, vall);
|
||||
|
||||
list<string>::const_iterator it = vall.begin();
|
||||
vector<string>::const_iterator it = vall.begin();
|
||||
udi.erase();
|
||||
string fn, ipath;
|
||||
switch (vall.size()) {
|
||||
|
|
|
@ -43,8 +43,8 @@ bool RclDynConf::insertNew(const string &sk, DynConfEntry &n, DynConfEntry &s,
|
|||
int maxlen)
|
||||
{
|
||||
// Is this doc already in list ? If it is we remove the old entry
|
||||
list<string> names = m_data.getNames(sk);
|
||||
list<string>::const_iterator it;
|
||||
vector<string> names = m_data.getNames(sk);
|
||||
vector<string>::const_iterator it;
|
||||
bool changed = false;
|
||||
for (it = names.begin(); it != names.end(); it++) {
|
||||
string oval;
|
||||
|
@ -61,7 +61,7 @@ bool RclDynConf::insertNew(const string &sk, DynConfEntry &n, DynConfEntry &s,
|
|||
}
|
||||
}
|
||||
|
||||
// Maybe reget list
|
||||
// Maybe reget things
|
||||
if (changed)
|
||||
names = m_data.getNames(sk);
|
||||
|
||||
|
@ -95,8 +95,8 @@ bool RclDynConf::insertNew(const string &sk, DynConfEntry &n, DynConfEntry &s,
|
|||
|
||||
bool RclDynConf::eraseAll(const string &sk)
|
||||
{
|
||||
list<string> names = m_data.getNames(sk);
|
||||
list<string>::const_iterator it;
|
||||
vector<string> names = m_data.getNames(sk);
|
||||
vector<string>::const_iterator it;
|
||||
for (it = names.begin(); it != names.end(); it++) {
|
||||
m_data.erase(*it, sk);
|
||||
}
|
||||
|
|
|
@ -98,8 +98,8 @@ template<typename Tp> list<Tp> RclDynConf::getList(const string &sk)
|
|||
{
|
||||
list<Tp> mlist;
|
||||
Tp entry;
|
||||
list<string> names = m_data.getNames(sk);
|
||||
for (list<string>::const_iterator it = names.begin();
|
||||
vector<string> names = m_data.getNames(sk);
|
||||
for (vector<string>::const_iterator it = names.begin();
|
||||
it != names.end(); it++) {
|
||||
string value;
|
||||
if (m_data.get(*it, value, sk)) {
|
||||
|
|
|
@ -70,9 +70,9 @@ bool DocSeqFiltered::setFiltSpec(DocSeqFiltSpec &filtspec)
|
|||
string val = filtspec.values[i];
|
||||
if (val.find("rclcat:") == 0) {
|
||||
string catg = val.substr(7);
|
||||
list<string> tps;
|
||||
vector<string> tps;
|
||||
m_config->getMimeCatTypes(catg, tps);
|
||||
for (list<string>::const_iterator it = tps.begin();
|
||||
for (vector<string>::const_iterator it = tps.begin();
|
||||
it != tps.end(); it++) {
|
||||
LOGDEB2(("Adding mime: [%s]\n", it->c_str()));
|
||||
m_spec.orCrit(DocSeqFiltSpec::DSFS_MIMETYPE, *it);
|
||||
|
|
|
@ -82,10 +82,10 @@ static Rcl::SearchData *wasaQueryToRcl(RclConfig *config, WasaQuery *wasa,
|
|||
"nor excl??";
|
||||
return 0;
|
||||
}
|
||||
list<string> mtypes;
|
||||
vector<string> mtypes;
|
||||
if (config && config->getMimeCatTypes((*it)->m_value, mtypes)
|
||||
&& !mtypes.empty()) {
|
||||
for (list<string>::iterator mit = mtypes.begin();
|
||||
for (vector<string>::iterator mit = mtypes.begin();
|
||||
mit != mtypes.end(); mit++) {
|
||||
if ((*it)->m_op == WasaQuery::OP_LEAF)
|
||||
sdata->addFiletype(*mit);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue