Skip to content

Commit

Permalink
Remove unused DQMStore::getAllTags.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dmitrijus Bugelskis committed Feb 23, 2018
1 parent 0d4d0a3 commit 5ff5346
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 55 deletions.
1 change: 0 additions & 1 deletion DQMServices/Core/interface/DQMStore.h
Expand Up @@ -728,7 +728,6 @@ class DQMStore
TObject ** obj);

public:
void getAllTags(std::vector<std::string> &into) const;
std::vector<MonitorElement*> getAllContents(const std::string &path,
uint32_t runNumber = 0,
uint32_t lumi = 0) const;
Expand Down
53 changes: 0 additions & 53 deletions DQMServices/Core/src/DQMStore.cc
Expand Up @@ -1823,59 +1823,6 @@ DQMStore::findObject(const std::string &dir,
: const_cast<MonitorElement *>(&*mepos));
}

/** get tags for various maps, return vector with strings of the form
<dir pathname>:<obj1>/<tag1>/<tag2>,<obj2>/<tag1>/<tag3>, etc. */
void
DQMStore::getAllTags(std::vector<std::string> &into) const
{
into.clear();
into.reserve(dirs_.size());

auto me = data_.end();
auto di = dirs_.begin();
auto de = dirs_.end();
char tagbuf[32]; // more than enough for '/' and up to 10 digits

for ( ; di != de; ++di)
{
MonitorElement proto(&*di, std::string());
auto mi = data_.lower_bound(proto);
auto m = mi;
size_t sz = di->size() + 2;
size_t nfound = 0;
for ( ; m != me && isSubdirectory(*di, *m->data_.dirname); ++m)
if (*di == *m->data_.dirname && (m->data_.flags & DQMNet::DQM_PROP_TAGGED))
{
// the tags count for '/' + up to 10 digits, otherwise ',' + ME name
sz += 1 + m->data_.objname.size() + 11;
++nfound;
}

if (! nfound)
continue;

auto istr
= into.insert(into.end(), std::string());

istr->reserve(sz);

*istr += *di;
*istr += ':';
for (sz = 0; mi != m; ++mi)
{
if (*di == *m->data_.dirname && (m->data_.flags & DQMNet::DQM_PROP_TAGGED))
{
sprintf(tagbuf, "/%u", mi->data_.tag);
if (sz > 0)
*istr += ',';
*istr += m->data_.objname;
*istr += tagbuf;
++sz;
}
}
}
}

/// get vector with children of folder, including all subfolders + their children;
/// must use an exact pathname
std::vector<MonitorElement*>
Expand Down
1 change: 0 additions & 1 deletion DQMServices/Examples/src/DQMSourceExample.cc
Expand Up @@ -131,7 +131,6 @@ void DQMSourceExample::beginJob() {
h6->setResetMe(true);
dbe_->showDirStructure();
std::vector<std::string> tags;
dbe_->getAllTags(tags);
for (size_t i = 0, e = tags.size(); i < e; ++i)
std::cout << "TAGS [" << i << "] = " << tags[i] << std::endl;
*/
Expand Down

0 comments on commit 5ff5346

Please sign in to comment.