BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
VeeVertex Class Reference

#include <VeeVertex.h>

Inheritance diagram for VeeVertex:

Public Member Functions

 VeeVertex (const std::string &name, ISvcLocator *pSvcLocator)
StatusCode initialize ()
StatusCode execute (const EventContext &ctx) const
StatusCode finalize ()

Detailed Description

Definition at line 7 of file VeeVertex.h.

Constructor & Destructor Documentation

◆ VeeVertex()

VeeVertex::VeeVertex ( const std::string & name,
ISvcLocator * pSvcLocator )

Definition at line 16 of file VeeVertex.cxx.

17 : Gaudi::Sequence( name, pSvcLocator ) {
18 // Declare the properties
19 declareProperty( "KShortReconstruction", m_recKShort = true );
20 declareProperty( "LambdaReconstruction", m_recLambda = true );
21 declareProperty( "GammaConversionReconstruction", m_recGC = true );
22}

Referenced by VeeVertex().

Member Function Documentation

◆ execute()

StatusCode VeeVertex::execute ( const EventContext & ctx) const

Definition at line 110 of file VeeVertex.cxx.

110 {
111 MsgStream log( msgSvc(), name() );
112
113 StatusCode sc = clearEvtRecVeeVertexCol( log );
114 if ( sc != StatusCode::SUCCESS ) { return sc; }
115
116 // std::vector<Algorithm*>::const_iterator it = subAlgorithms()->begin();
117 // std::vector<Algorithm*>::const_iterator end = subAlgorithms()->end();
118 // for ( ; it != end; it++ )
119 // {
120 // sc = ( *it )->execute( ctx );
121 // if ( sc.isFailure() ) { log << "Error executing selection " << ( *it )->name() <<
122 // endmsg; }
123 // }
124
125 for ( auto subAlg : *subAlgorithms() )
126 {
127 sc = subAlg->execute( ctx );
128 if ( sc.isFailure() ) { log << "Error executing selection " << subAlg->name() << endmsg; }
129 }
130
131 DataObject* aEvtRecVeeVertexCol;
132 eventSvc()->findObject( "/Event/EvtRec/EvtRecVeeVertexCol", aEvtRecVeeVertexCol );
133 if ( aEvtRecVeeVertexCol == NULL ) { registerEvtRecVeeVertexCol( log ); }
134
135 return StatusCode::SUCCESS;
136}
IMessageSvc * msgSvc()

◆ finalize()

StatusCode VeeVertex::finalize ( )

Definition at line 139 of file VeeVertex.cxx.

139 {
140
141 MsgStream log( msgSvc(), name() );
142 log << MSG::INFO << "in finalize()" << endmsg;
143 return StatusCode::SUCCESS;
144}

◆ initialize()

StatusCode VeeVertex::initialize ( )

Definition at line 25 of file VeeVertex.cxx.

25 {
26
27 MsgStream log( msgSvc(), name() );
28
29 log << MSG::INFO << "creating VeeVertex sub Algorithm" << endmsg;
30
31 StatusCode sc;
32
33 if ( m_recKShort )
34 {
35 sc = createSubAlgorithm( "KShortReconstruction", "KShortReconstruction",
36 m_KShortReconstruction );
37 if ( sc.isFailure() )
38 {
39 log << MSG::ERROR << "Error while creating KShortReconstruction" << endmsg;
40 return StatusCode::FAILURE;
41 }
42 }
43 if ( m_recLambda )
44 {
45 sc = createSubAlgorithm( "LambdaReconstruction", "LambdaReconstruction",
46 m_LambdaReconstruction );
47 if ( sc.isFailure() )
48 {
49 log << MSG::ERROR << "Error while creating LambdaReconstruction" << endmsg;
50 return StatusCode::FAILURE;
51 }
52 }
53 if ( m_recGC )
54 {
55 sc = createSubAlgorithm( "GammaConversionReconstruction", "GammaConversionReconstruction",
56 m_gcReconstruction );
57 if ( sc.isFailure() )
58 {
59 log << MSG::ERROR << "Error while creating GammaConversionReconstruction" << endmsg;
60 return StatusCode::FAILURE;
61 }
62 }
63
64 log << MSG::INFO << "Calling Sequence::initialize()" << endmsg;
65 // return StatusCode::SUCCESS;
66 return Sequence::initialize();
67}

The documentation for this class was generated from the following files: