| The Gaudi Framework v27r1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
concurrency::RankerByProductConsumption Class Reference

`#include <src/EFGraphVisitors.h>`

Inheritance diagram for concurrency::RankerByProductConsumption:
[legend]
Collaboration diagram for concurrency::RankerByProductConsumption:
[legend]

## Public Member Functions
| RankerByProductConsumption ()
| Constructor. More...
virtual | ~RankerByProductConsumption ()
| Destructor. More...
virtual bool | visitEnter (DecisionNode &) const
virtual bool | visit (DecisionNode &)
virtual bool | visitLeave (DecisionNode &) const
virtual bool | visitEnter (AlgorithmNode &) const
virtual bool | visit (AlgorithmNode &node)
virtual void | reset ()
Public Member Functions inherited from concurrency::IGraphVisitor
virtual | ~IGraphVisitor ()

## Additional Inherited Members
Public Attributes inherited from concurrency::IGraphVisitor
int | m_nodesSucceeded
int | m_slotNum

## Detailed Description

Definition at line 64 of file EFGraphVisitors.h.

## Constructor & Destructor Documentation

concurrency::RankerByProductConsumption::RankerByProductConsumption | ( |  | ) |
| inline

Constructor.

Definition at line 67 of file EFGraphVisitors.h.

67 {
68 m_nodesSucceeded = 0;
69 m_slotNum = -1;
70 };
concurrency::IGraphVisitor::m_slotNum
int m_slotNum
Definition: IGraphVisitor.h:24
concurrency::IGraphVisitor::m_nodesSucceeded
int m_nodesSucceeded
Definition: IGraphVisitor.h:23

virtual concurrency::RankerByProductConsumption::~RankerByProductConsumption | ( |  | ) |
| inline virtual

Destructor.

Definition at line 72 of file EFGraphVisitors.h.

72 {};

## Member Function Documentation

virtual void concurrency::RankerByProductConsumption::reset | ( |  | ) |
| inline virtual

Implements concurrency::IGraphVisitor.

Definition at line 86 of file EFGraphVisitors.h.

86 { m_nodesSucceeded = 0; }
concurrency::IGraphVisitor::m_nodesSucceeded
int m_nodesSucceeded
Definition: IGraphVisitor.h:23

virtual bool concurrency::RankerByProductConsumption::visit | ( | DecisionNode & |  | ) |
| inline virtual

Implements concurrency::IGraphVisitor.

Definition at line 76 of file EFGraphVisitors.h.

76 {return true;};

bool concurrency::RankerByProductConsumption::visit | ( | AlgorithmNode & | node | ) |
| virtual

Implements concurrency::IGraphVisitor.

Definition at line 154 of file EFGraphVisitors.cpp.

154 {
155
156 auto& products = node.getOutputDataNodes();
157 float rank = 0;
158
159 for (auto p : products)
160 rank += p->getConsumers().size();
161
162 node.setRank(rank);
163 /*std::stringstream s;
164 s << node.getNodeName() << ", " << rank << "\n";
165 std::ofstream myfile;
166 myfile.open("AlgoRank.csv", std::ios::app);
167 myfile << s.str();
168 myfile.close();*/
169
170 return true;
171 }

virtual bool concurrency::RankerByProductConsumption::visitEnter | ( | DecisionNode & |  | ) | const
| inline virtual

Implements concurrency::IGraphVisitor.

Definition at line 74 of file EFGraphVisitors.h.

74 {return true;};

virtual bool concurrency::RankerByProductConsumption::visitEnter | ( | AlgorithmNode & |  | ) | const
| inline virtual

Implements concurrency::IGraphVisitor.

Definition at line 81 of file EFGraphVisitors.h.

81 {return true;};

virtual bool concurrency::RankerByProductConsumption::visitLeave | ( | DecisionNode & |  | ) | const
| inline virtual

Implements concurrency::IGraphVisitor.

Definition at line 78 of file EFGraphVisitors.h.

78 {return true;};

The documentation for this class was generated from the following files:

- GaudiHive/src/EFGraphVisitors.h
- GaudiHive/src/EFGraphVisitors.cpp