CMS 3D CMS Logo

TinyDomTest2.cc
Go to the documentation of this file.
2 
3 #include <iostream>
4 #include <utility>
5 
8 
9 using std::vector;
10 using std::cout;
11 using std::endl;
12 
13 TinyDomTest2::TinyDomTest2(const TinyDom2 & td2) : dom_(td2) { }
14 
15 unsigned int TinyDomTest2::allNodes(const Node2 & n2, vector<const AttList2*> & at2)
16 {
18  cout << "Size of graph: " << TinyDomTest2::dom_.size() << endl;
19  while (it++ != dom_.end())
20  {
21  if (n2.first.sameName(dom_.nodeData(it).first))
22  {
23  at2.push_back(&(dom_.nodeData(it).second));
24  }
25  }
26  return at2.size();
27 }
adj_list::size_type size() const
Definition: adjgraph.h:201
const N & nodeData(const edge_type &) const
Definition: adjgraph.h:317
unsigned int allNodes(const Node2 &n2, std::vector< const AttList2 * > &at2)
Definition: TinyDomTest2.cc:15
adj_list::const_iterator const_adj_iterator
Definition: adjgraph.h:125
TinyDomTest2(const TinyDom2 &td2)
Definition: TinyDomTest2.cc:13
std::pair< TagName, AttList2 > Node2
Definition: TinyDom2.h:16
adj_iterator begin()
Definition: adjgraph.h:197
const TinyDom2 & dom_
Definition: TinyDomTest2.h:17
adj_iterator end()
Definition: adjgraph.h:199