CMS 3D CMS Logo

TinyDomTest.cc
Go to the documentation of this file.
4 
5 #include <utility>
6 
7 TinyDomTest::TinyDomTest(const TinyDom &d) : dom_(d) {}
8 
9 unsigned int TinyDomTest::allNodes(const NodeName &tagName, std::vector<const AttList *> &result) {
10  result.clear();
13  for (; it != ed; ++it) {
14  const TinyDom::edge_list &el = *it;
15  TinyDom::edge_list::const_iterator el_it = el.begin();
16  TinyDom::edge_list::const_iterator el_ed = el.end();
17  for (; el_it != el_ed; ++el_it) {
18  if (dom_.nodeData(el_it->first).sameName(tagName)) {
19  result.emplace_back(&dom_.edgeData(el_it->second));
20  }
21  }
22  }
23  return result.size();
24 }
TagName
Definition: TagName.h:9
TagName.h
TinyDomTest.h
math::Graph< NodeName, AttList >::edge_list
std::vector< edge_type > edge_list
Definition: Graph.h:19
TinyDomTest::allNodes
unsigned int allNodes(const NodeName &, std::vector< const AttList * > &)
Definition: TinyDomTest.cc:9
math::Graph::edgeData
const E & edgeData(index_type i) const
Definition: Graph.h:158
math::Graph::begin
adj_iterator begin()
Definition: Graph.h:172
TinyDomTest::dom_
const TinyDom & dom_
Definition: TinyDomTest.h:15
Graph.h
TinyDomTest::TinyDomTest
TinyDomTest(const TinyDom &)
Definition: TinyDomTest.cc:7
math::Graph::end
adj_iterator end()
Definition: Graph.h:174
ztail.d
d
Definition: ztail.py:151
math::Graph
Definition: Graph.h:13
mps_fire.result
result
Definition: mps_fire.py:311
math::Graph::nodeData
const N & nodeData(const edge_type &) const
Definition: Graph.h:272
JetPartonCorrections_cff.tagName
tagName
Definition: JetPartonCorrections_cff.py:12
math::Graph< NodeName, AttList >::const_adj_iterator
adj_list::const_iterator const_adj_iterator
Definition: Graph.h:105