ATLAS Offline Software
ConditionTestAlg.cxx
Go to the documentation of this file.
1 
3 /*
4  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // ConditionTestAlg.cxx
8 // Implementation file for class ConditionTestAlg
9 // Author: B. Wynne <bwynne@cern.ch>
11 
12 #include "ConditionTestAlg.h"
13 
14 // STL includes
15 
16 // FrameWork includes
18 
19 namespace AthViews {
20 
22 // Public methods:
24 
25 // Constructors
28  ISvcLocator* pSvcLocator ) :
29  ::AthAlgorithm( name, pSvcLocator )
30 {
31  //
32  // Property declaration
33  //
34  //declareProperty( "Property", m_nProperty );
35 }
36 
37 // Destructor
40 {}
41 
42 // Athena Algorithm's Hooks
45 {
46  ATH_MSG_INFO ("Initializing " << name() << "...");
47 
49 
50  return StatusCode::SUCCESS;
51 }
52 
54 {
55  ATH_MSG_INFO ("Finalizing " << name() << "...");
56 
57  return StatusCode::SUCCESS;
58 }
59 
61 {
62  ATH_MSG_DEBUG ("Executing " << name() << "...");
63 
64 #ifdef GAUDI_SYSEXECUTE_WITHCONTEXT
65  const EventContext& ctx = getContext();
66 #else
67  const EventContext& ctx = *getContext();
68 #endif
69 
70  ATH_MSG_INFO( name() << " running with store " << Atlas::getExtendedEventContext(ctx).proxy()->name() );
71 
72  // Make a (large) validity range
73  EventIDBase begin (0,
74  EventIDBase::UNDEFEVT, // event
75  EventIDBase::UNDEFNUM, // timestamp
76  EventIDBase::UNDEFNUM, // timestamp ns
77  0);
78  EventIDBase end (10000,
79  EventIDBase::UNDEFEVT, // event
80  EventIDBase::UNDEFNUM, // timestamp
81  EventIDBase::UNDEFNUM, // timestamp ns
82  10000);
83  EventIDRange range( begin, end );
84 
85  // Write a dummy object with this validity range
87  ATH_CHECK( condHandleTest.record( range, std::make_unique< CondDataObj >( 987 ) ) );
88 
89  return StatusCode::SUCCESS;
90 }
91 
92 } //> end namespace AthViews
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:392
AthViews::ConditionTestAlg::~ConditionTestAlg
virtual ~ConditionTestAlg()
Destructor:
Definition: ConditionTestAlg.cxx:39
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
ExtendedEventContext.h
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
SG::WriteCondHandle::record
StatusCode record(const EventIDRange &range, T *t)
record handle, with explicit range DEPRECATED
Definition: WriteCondHandle.h:157
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
Atlas::getExtendedEventContext
const ExtendedEventContext & getExtendedEventContext(const EventContext &ctx)
Retrieve an extended context from a context object.
Definition: ExtendedEventContext.cxx:32
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AthViews::ConditionTestAlg::m_condKeyTest
SG::WriteCondHandleKey< CondDataObj > m_condKeyTest
Containers.
Definition: ConditionTestAlg.h:57
plotBeamSpotVxVal.range
range
Definition: plotBeamSpotVxVal.py:195
AthViews::ConditionTestAlg::finalize
virtual StatusCode finalize()
Definition: ConditionTestAlg.cxx:53
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
AthAlgorithm
Definition: AthAlgorithm.h:47
AthViews::ConditionTestAlg::ConditionTestAlg
ConditionTestAlg()
Default constructor:
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
AthViews
Definition: ViewDataVerifier.cxx:18
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
AthViews::ConditionTestAlg::initialize
virtual StatusCode initialize()
Definition: ConditionTestAlg.cxx:44
SG::WriteCondHandle
Definition: WriteCondHandle.h:26
AthViews::ConditionTestAlg::execute
virtual StatusCode execute()
Definition: ConditionTestAlg.cxx:60
ConditionTestAlg.h