ATLAS Offline Software
Loading...
Searching...
No Matches
UnitTestService1.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
6
7
8
9#ifndef ASG_TOOLS__UNIT_TEST_SERVICE1_H
10#define ASG_TOOLS__UNIT_TEST_SERVICE1_H
11
15
16namespace asg
17{
22
23 struct UnitTestService1 : extends<AsgService, IUnitTestService1>
24 {
25 public:
27 UnitTestService1 (const std::string& name, ISvcLocator* pSvcLocator);
28
31
32 virtual StatusCode initialize () override;
33 virtual std::string getPropertyString () const override;
34 virtual int getPropertyInt () const override;
35 virtual void setPropertyInt (int val_property) override;
36 virtual bool isInitialized () const override;
37
38 private:
40 bool m_isInitialized{false};
41
43 Gaudi::Property<std::string> m_propertyString{this, "propertyString", {}, "the string property"};
44
46 Gaudi::Property<int> m_propertyInt{this, "propertyInt", -7, "the integer property"};
47
49 Gaudi::Property<bool> m_initializeFail{this, "initializeFail", false, "whether initialize should fail"};
50 };
51}
52
53#endif
virtual std::string getPropertyString() const override
bool m_isInitialized
whether initialize has been called
virtual void setPropertyInt(int val_property) override
Gaudi::Property< int > m_propertyInt
the integer property
virtual bool isInitialized() const override
Gaudi::Property< bool > m_initializeFail
whether initialize should fail
Gaudi::Property< std::string > m_propertyString
the string property
UnitTestService1(const std::string &name, ISvcLocator *pSvcLocator)
standard constructor
virtual int getPropertyInt() const override
virtual StatusCode initialize() override
~UnitTestService1()
standard destructor