|
ATLAS Offline Software
|
Go to the documentation of this file.
14 const std::string&
name,
29 return StatusCode::SUCCESS;
34 const EventContext& ctx )
const {
45 if ( primaryVertex ==
nullptr ) {
46 ATH_MSG_ERROR(
"No primary vertex has been found for this event!" );
47 return StatusCode::FAILURE;
50 "," << primaryVertex->
y() <<
51 "," << primaryVertex->
z() <<
")" );
61 const std::vector< TrigCompositeUtils::LinkInfo< xAOD::JetContainer >> myFeature = TrigCompositeUtils::findLinks< xAOD::JetContainer >(outputDecision,
TrigCompositeUtils::featureString(), TrigDefs::lastFeatureOfType);
63 if (myFeature.size() != 1) {
65 <<
", found " << myFeature.size());
66 return StatusCode::FAILURE;
70 const xAOD::Jet *myJet = *(myFeature.at(0).link);
71 double jetPt = myJet->
p4().Et();
72 double jetEta = myJet->
eta();
73 double jetPhi = myJet->
phi();
81 ATH_MSG_DEBUG(
" ** Imposing Z constraint while building RoI" );
92 jetPhi, phiMinus, phiPlus,
93 primaryVertex->
z(),zMinus,zPlus );
106 return StatusCode::SUCCESS;
111 if ( vertexContainer->
size() == 0 ) {
112 ATH_MSG_WARNING(
"Vertex Container has size 0! This can't be right!" );
116 for (
unsigned int i(0);
i<vertexContainer->
size();
i++ ) {
122 ATH_MSG_DEBUG(
"None of the vertexes in the vertex container is a primary vertex!" );
124 return vertexContainer->
at(0);
float x() const
Returns the x position.
T wrapToPi(T phi)
Wrap angle in radians to [-pi, pi].
virtual double phi() const
The azimuthal angle ( ) of the particle.
nope - should be used for standalone also, perhaps need to protect the class def bits #ifndef XAOD_AN...
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
::StatusCode StatusCode
StatusCode definition for legacy code.
const_pointer_type get() const
Dereference the pointer, but don't cache anything.
float z() const
Returns the z position.
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
SG::WriteHandle< CONT > createAndStoreNoAux(const SG::WriteHandleKey< CONT > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Creates and right away records the Container CONT with the key.
Class used to describe composite objects in the HLT.
size_t index() const
Return the index of this element within its container.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual double eta() const
The pseudorapidity ( ) of the particle.
const std::string & featureString()
Helper for azimuthal angle calculations.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
virtual FourMom_t p4() const
The full 4-momentum of the particle.
Class describing a Vertex.
#define ATH_MSG_WARNING(x)
float y() const
Returns the y position.
const std::string & roiString()
Athena::TPCnvVers::Current TrigRoiDescriptor
const T * at(size_type n) const
Access an element, as an rvalue.
size_type size() const noexcept
Returns the number of elements in the collection.