ATLAS Offline Software
Loading...
Searching...
No Matches
BunchCrossingConfProviderBase.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5// $Id: BunchCrossingConfProviderBase.cxx 748399 2016-05-19 14:55:47Z krasznaa $
6
7// Local include(s):
10
11namespace Trig {
12
13 //
14 // Initialize the static variable(s):
15 //
16 const std::string
18
27 std::vector< int >
29
30 std::vector< int > bunches;
31 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
32 if( isFilled( i ) ) {
33 bunches.push_back( i );
34 }
35 }
36
37 return bunches;
38 }
39
47 std::vector< float >
49
50 std::vector< float > intensities;
51 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
52 if( isFilled( i ) ) {
53 intensities.push_back( bcIntensity( i, Beam1 ) );
54 }
55 }
56
57 return intensities;
58 }
59
67 std::vector< float >
69
70 std::vector< float > intensities;
71 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
72 if( isFilled( i ) ) {
73 intensities.push_back( bcIntensity( i, Beam2 ) );
74 }
75 }
76
77 return intensities;
78 }
79
87 std::vector< int >
89
90 std::vector< int > bunches;
91 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
92 if( isUnpaired( i ) && isBeam1( i ) ) {
93 bunches.push_back( i );
94 }
95 }
96
97 return bunches;
98 }
99
107 std::vector< int >
109
110 std::vector< int > bunches;
111 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
112 if( isUnpaired( i ) && isBeam2( i ) ) {
113 bunches.push_back( i );
114 }
115 }
116
117 return bunches;
118 }
119
127 std::vector< float >
129
130 std::vector< float > intensities;
131 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
132 if( isUnpaired( i ) && isBeam1( i ) ) {
133 intensities.push_back( bcIntensity( i, Beam1 ) );
134 }
135 }
136
137 return intensities;
138 }
139
147 std::vector< float >
149
150 std::vector< float > intensities;
151 for( int i = 0; i < BunchCrossing::MAX_BCID; ++i ) {
152 if( isUnpaired( i ) && isBeam2( i ) ) {
153 intensities.push_back( bcIntensity( i, Beam2 ) );
154 }
155 }
156
157 return intensities;
158 }
159
160} // namespace Trig
virtual std::vector< int > configuredBCIDs() const
Function providing the BCIDs of the configured colliding bunches.
virtual std::vector< int > configuredUnpairedBCIDsBeam2() const
Function providing the BCIDs of the configured unpaired bunches.
virtual std::vector< float > configuredIntensitiesBeam2() const
Function providing the intensities of the configured colliding bunches.
virtual std::vector< float > configuredUnpairedIntensitiesBeam2() const
Function providing the intensities of the configured unpaired bunches.
virtual std::vector< float > configuredUnpairedIntensitiesBeam1() const
Function providing the intensities of the configured unpaired bunches.
virtual std::vector< int > configuredUnpairedBCIDsBeam1() const
Function providing the BCIDs of the configured unpaired bunches.
virtual std::vector< float > configuredIntensitiesBeam1() const
Function providing the intensities of the configured colliding bunches.
static const std::string BUNCH_CONFIG_INCIDENT_NAME
Type name for the incident that such tools should emit.
static const int MAX_BCID
The maximum number of bunches that can be in the LHC.
virtual float bcIntensity(bcid_type bcid=0, BeamType type=Crossing) const =0
Function returning the "intensity" of a given bunch(-crossing)
virtual bool isBeam2(bcid_type bcid=0) const =0
Function deciding if there was a bunch from "beam 2" in this bunch crossing.
virtual bool isFilled(bcid_type bcid=0) const =0
The simplest query: Is the bunch crossing filled or not?
virtual bool isUnpaired(bcid_type bcid=0) const =0
Function deciding if a given bunch crossing has an unpaired bunch.
virtual bool isBeam1(bcid_type bcid=0) const =0
Function deciding if there was a bunch from "beam 1" in this bunch crossing.
@ Beam1
The returned intensity should be for "beam 1".
@ Beam2
The returned intensity should be for "beam 2".
The common trigger namespace for trigger analysis tools.