ATLAS Offline Software
Loading...
Searching...
No Matches
AFPTrack_v1.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3*/
4
13
14
15// xAOD include(s):
17
18// Local include(s):
21
22namespace xAOD
23{
24 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, int, stationID, setStationID)
25 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, xLocal, setXLocal)
26 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, yLocal, setYLocal)
27 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, zLocal, setZLocal)
28 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, xSlope, setXSlope)
29 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, ySlope, setYSlope)
30 // AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, float, zSlope, setZSlope)
31 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER (AFPTrack_v1, unsigned int, nHoles, setNHoles)
35
36 AUXSTORE_OBJECT_SETTER_AND_GETTER (AFPTrack_v1, std::vector< AFPTrack_v1::AFPHitLink_t >, hits, setHits)
37 static const SG::AuxElement::Accessor< std::vector<AFPTrack_v1::AFPHitLink_t> > hitsAcc( "hits" );
38
40 {
41 hitsAcc( *this ).push_back( link );
42 }
43
45 // Prepare the hits links for persistification:
46 if( hitsAcc.isAvailableWritable( *this ) ) {
47 std::vector<AFPHitLink_t>::iterator end = hitsAcc( *this ).end();
48 for(std::vector<AFPHitLink_t>::iterator itr = hitsAcc( *this ).begin(); itr != end; ++itr )
49 itr->toPersistent();
50
51 }
52
53 return;
54 }
55
56
57}
Header file with typedef for class AFPSiHitContainer_v1.
Header file for the AFPTrack class.
#define AUXSTORE_PRIMITIVE_SETTER_AND_GETTER(CL, TYPE, NAME, SETTER)
Macro creating the accessors of primitive auxiliary properties.
#define AUXSTORE_OBJECT_SETTER_AND_GETTER(CL, TYPE, NAME, SETTER)
Macro creating the accessors of complex auxiliary properties.
static const uint32_t nHits
Class representing a track reconstructed in AFP.
Definition AFPTrack_v1.h:36
void addHit(const AFPHitLink_t &newHit)
Add a link to a pixel used to reconstruct the track.
void toPersistent()
Function making sure that the object is ready for persistification i.e. saving.
ElementLink< AFPSiHitContainer > AFPHitLink_t
Type of a link to the hit.
Definition AFPTrack_v1.h:39
double chi2(TH1 *h0, TH1 *h1)
Forward declaration.
STL namespace.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
static const SG::AuxElement::Accessor< std::vector< AFPToFTrack_v1::AFPToFHitLink_t > > hitsAcc("bars")