GENIEGenerator
Loading...
Searching...
No Matches
Framework
GHEP
GHepVirtualList.cxx
Go to the documentation of this file.
1
//____________________________________________________________________________
2
/*
3
Copyright (c) 2003-2025, The GENIE Collaboration
4
For the full text of the license visit http://copyright.genie-mc.org
5
6
Costas Andreopoulos <c.andreopoulos \at cern.ch>
7
University of Liverpool
8
*/
9
//____________________________________________________________________________
10
11
#include <cassert>
12
#include <string>
13
14
#include <TLorentzVector.h>
15
16
#include "
Framework/GHEP/GHepParticle.h
"
17
#include "
Framework/GHEP/GHepVirtualList.h
"
18
#include "
Framework/GHEP/GHepStatus.h
"
19
#include "
Framework/Interaction/Interaction.h
"
20
#include "
Framework/Messenger/Messenger.h
"
21
#include "
Framework/ParticleData/PDGUtils.h
"
22
23
using
std::string;
24
using namespace
genie
;
25
26
ClassImp
(
GHepVirtualList
)
27
28
//___________________________________________________________________________
29
GHepVirtualList::GHepVirtualList
() :
30
TClonesArray(
"genie::GHepParticle"
)
31
{
32
this->SetOwner(
false
);
33
}
34
//___________________________________________________________________________
35
GHepVirtualList::GHepVirtualList
(
int
size) :
36
TClonesArray(
"genie::GHepParticle"
, size)
37
{
38
this->SetOwner(
false
);
39
}
40
//___________________________________________________________________________
41
GHepVirtualList::GHepVirtualList
(
const
GHepVirtualList
& vlist) :
42
TClonesArray(
"genie::GHepParticle"
, vlist.GetEntries())
43
{
44
this->SetOwner(
false
);
45
46
// clean up
47
this->Clear();
48
49
// adjust size
50
this->Expand(vlist.GetEntries());
51
52
// copy event record entries
53
unsigned
int
ientry = 0;
54
GHepParticle
* p = 0;
55
TIter ghepiter(&vlist);
56
while
( (p = (
GHepParticle
*) ghepiter.Next()) ) (*this)[ientry++] = p;
57
}
58
//___________________________________________________________________________
59
GHepVirtualList::~GHepVirtualList
()
60
{
61
this->Clear();
62
}
63
//___________________________________________________________________________
GHepParticle.h
GHepStatus.h
ClassImp
ClassImp(GHepVirtualList) GHepVirtualList
Definition
GHepVirtualList.cxx:26
GHepVirtualList.h
Interaction.h
Messenger.h
PDGUtils.h
genie::GHepParticle
STDHEP-like event record entry that can fit a particle or a nucleus.
Definition
GHepParticle.h:39
genie::GHepVirtualList
A GHepVirtualList is a 'virtual' collection of GHepParticles. Is virtual because it does not own but ...
Definition
GHepVirtualList.h:35
genie::GHepVirtualList::~GHepVirtualList
~GHepVirtualList()
Definition
GHepVirtualList.cxx:59
genie::GHepVirtualList::GHepVirtualList
GHepVirtualList()
genie
THE MAIN GENIE PROJECT NAMESPACE
Definition
AlgCmp.h:25
Generated on
for GENIEGenerator by
1.14.0