ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
ECCE @ EIC Software
Deprecated List
Modules
Namespaces
Classes
Files
File List
acts
analysis
coresoftware
blob
master
calibrations
generators
offline
database
framework
ffamodules
ffaobjects
frog
fun4all
fun4allraw
phool
getClass.h
PHCompositeNode.cc
PHCompositeNode.h
PHDataNode.h
PHDataNodeIterator.h
PHFlag.cc
PHFlag.h
PHIODataNode.h
PHIOManager.h
PHLog.h
PHMessage.cc
PHMessage.h
PHNode.cc
PHNode.h
PHNodeIntegrate.cc
PHNodeIntegrate.h
PHNodeIOManager.cc
PHNodeIOManager.h
PHNodeIterator.cc
PHNodeIterator.h
PHNodeOperation.h
PHNodeReset.cc
PHNodeReset.h
PHObject.cc
PHObject.h
PHObjectLinkDef.h
phool.h
phooldefs.h
PHOperation.cc
PHOperation.h
PHPointerList.h
PHPointerListIterator.h
PHRandomSeed.cc
PHRandomSeed.h
PHTimer.cc
PHTimer.h
PHTimeServer.cc
PHTimeServer.h
PHTimeStamp.cc
PHTimeStamp.h
PHTimeStampLinkDef.h
PHTypedNodeIterator.h
recoConsts.cc
recoConsts.h
phoolraw
packages
QA
simulation
Doxygen_Assist
ecce-detectors
fun4all_eicdetectors
geant4
macros
online_distribution
tutorials
doxygen_mainpage.h
File Members
External Links
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
PHNodeIntegrate.cc
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file PHNodeIntegrate.cc
1
#include "
PHNodeIntegrate.h
"
2
3
#include "
PHCompositeNode.h
"
4
#include "
PHDataNode.h
"
5
#include "
PHIODataNode.h
"
6
#include "
PHNode.h
"
7
#include "
PHObject.h
"
8
#include "
getClass.h
"
9
10
#include <iostream>
11
#include <string>
12
13
using namespace
std;
14
15
void
PHNodeIntegrate::perform
(
PHNode
*node)
16
{
17
if
(verbosity > 0)
18
{
19
cout <<
"PHNodeIntegrate: Integrating "
<< node->
getName
() << endl;
20
}
21
if
(node->
getType
() ==
"PHDataNode"
|| node->
getType
() ==
"PHIODataNode"
)
22
{
23
if
(node->
getObjectType
() ==
"PHObject"
)
24
{
25
PHObject
*obj =
static_cast<
PHDataNode<PHObject>
*
>
(node)->getData();
26
if
(obj->
Integrate
())
27
{
28
PHObject
*sumobj = findNode::getClass<PHObject>(runsumnode, node->
getName
());
29
if
(sumobj)
30
{
31
sumobj->
Integrate
(obj);
32
// now copy the summed object to the runwise node
33
// since the runwise nodes were copied from the input file
34
// we are guaranteed that it exists (and we handle only
35
// objects which come from the current input file
36
PHObject
*runobj = findNode::getClass<PHObject>(runnode, node->
getName
());
37
runobj->
CopyFrom
(sumobj);
38
}
39
else
40
{
41
// since this object was also copied to the node tree we only need
42
// to store it in case a second file gets opened where this one then
43
// serves as the object which contains the sum
44
sumobj = obj->
CloneMe
();
45
PHIODataNode<PHObject>
*sumobjnode =
new
PHIODataNode<PHObject>
(sumobj, node->
getName
(),
"PHObject"
);
46
runsumnode->addNode(sumobjnode);
47
}
48
}
49
}
50
}
51
}
coresoftware
blob
master
offline
framework
phool
PHNodeIntegrate.cc
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:24:34
using
1.8.2 with
ECCE GitHub integration