Loading [MathJax]/extensions/tex2jax.js
The Gaudi Framework
v36r16 (ea80daf8)
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Typedefs
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
Enumerator
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
y
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Enumerations
a
c
d
e
f
i
l
m
n
o
p
r
s
t
Enumerator
a
b
c
d
e
f
i
j
k
l
m
n
o
p
r
s
t
u
v
w
Properties
Related Functions
:
a
b
c
d
e
g
h
i
m
o
p
s
t
v
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Functions
_
b
c
e
f
g
h
i
l
m
n
o
p
r
s
t
u
z
Variables
a
b
c
d
e
g
h
i
m
o
p
r
s
t
v
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
w
Enumerations
Enumerator
c
e
f
p
u
v
Macros
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
GaudiEnv.h
Go to the documentation of this file.
1
/***********************************************************************************\
2
* (c) Copyright 1998-2019 CERN for the benefit of the LHCb and ATLAS collaborations *
3
* *
4
* This software is distributed under the terms of the Apache version 2 licence, *
5
* copied verbatim in the file "LICENSE". *
6
* *
7
* In applying this licence, CERN does not waive the privileges and immunities *
8
* granted to it by virtue of its status as an Intergovernmental Organization *
9
* or submit itself to any jurisdiction. *
10
\***********************************************************************************/
11
#pragma once
12
#include "
GaudiKernel/Bootstrap.h
"
13
#include "
GaudiKernel/IAppMgrUI.h
"
14
#include "
GaudiKernel/IProperty.h
"
15
#include "
GaudiKernel/ISvcLocator.h
"
16
#include "
GaudiKernel/ISvcManager.h
"
17
#include "
GaudiKernel/IToolSvc.h
"
18
#include "
GaudiKernel/SmartIF.h
"
19
#include <sstream>
20
#include <stdexcept>
21
namespace
GaudiTesting
{
22
void
throwConditionFailed
(
bool
condition,
const
std::string
file_name,
int
line_no,
23
const
std::string
condition_string );
24
}
25
26
#define Ensures( a ) GaudiTesting::throwConditionFailed( a, __FILE__, __LINE__, #a )
27
#ifndef NDEBUG
28
# define DEBUG_TRACE( a ) \
29
do { a; } while ( false )
30
#else
31
# define DEBUG_TRACE( a ) \
32
do { \
33
} while ( false )
34
#endif
35
36
namespace
GaudiTesting
{
37
class
GaudiEnv
{
38
public
:
39
GaudiEnv
()
40
:
m_iface
{
Gaudi::createApplicationMgr
() }
41
,
m_svcMgr
(
m_iface
)
42
,
m_appMgr
(
m_iface
)
43
,
m_propMgr
(
m_iface
)
44
,
m_svcLoc
(
m_iface
) {
45
Ensures
(
m_iface
!=
nullptr
);
46
Ensures
(
m_svcMgr
.
isValid
() );
47
Ensures
(
m_appMgr
.
isValid
() );
48
Ensures
(
m_propMgr
.
isValid
() );
49
Ensures
(
m_svcLoc
.
isValid
() );
50
m_toolSvc
=
m_svcLoc
->service(
"ToolSvc"
);
51
Ensures
(
m_toolSvc
.
isValid
() );
52
// pSvcLoc =
53
(void)
m_svcLoc
.
pRef
();
54
m_propMgr
->setProperty(
"EvtSel"
,
"NONE"
).ignore();
55
m_propMgr
->setProperty(
"JobOptionsType"
,
"NONE"
).ignore();
56
Ensures
( (
m_appMgr
->configure().isSuccess() ) );
57
Ensures
( (
m_appMgr
->initialize().isSuccess() ) );
58
}
59
IInterface
*
m_iface
;
60
SmartIF<ISvcManager>
m_svcMgr
;
61
SmartIF<IAppMgrUI>
m_appMgr
;
62
SmartIF<IProperty>
m_propMgr
;
63
SmartIF<ISvcLocator>
m_svcLoc
;
64
SmartIF<IToolSvc>
m_toolSvc
;
65
};
66
}
// namespace GaudiTesting
GaudiTesting::GaudiEnv::GaudiEnv
GaudiEnv()
Definition:
GaudiEnv.h:39
GaudiTesting::GaudiEnv::m_iface
IInterface * m_iface
Definition:
GaudiEnv.h:59
Gaudi::createApplicationMgr
GAUDI_API IAppMgrUI * createApplicationMgr(const std::string &dllname, const std::string &factname)
std::string
STL class.
GaudiTesting::GaudiEnv::m_toolSvc
SmartIF< IToolSvc > m_toolSvc
Definition:
GaudiEnv.h:64
GaudiTesting::GaudiEnv
Definition:
GaudiEnv.h:37
GaudiTesting
Definition:
MyServiceWithTool.cpp:15
GaudiTesting::throwConditionFailed
void throwConditionFailed(bool condition, const std::string file_name, int line_no, const std::string condition_string)
Definition:
ToolVisitorTestLib.cpp:25
IAppMgrUI.h
GaudiTesting::GaudiEnv::m_appMgr
SmartIF< IAppMgrUI > m_appMgr
Definition:
GaudiEnv.h:61
IToolSvc.h
SmartIF::pRef
TYPE *& pRef()
Get reference to the pointer.
Definition:
SmartIF.h:89
SmartIF.h
SmartIF::isValid
bool isValid() const
Allow for check if smart pointer is valid.
Definition:
SmartIF.h:72
GaudiTesting::GaudiEnv::m_svcLoc
SmartIF< ISvcLocator > m_svcLoc
Definition:
GaudiEnv.h:63
SmartIF< ISvcManager >
GaudiTesting::GaudiEnv::m_svcMgr
SmartIF< ISvcManager > m_svcMgr
Definition:
GaudiEnv.h:60
IInterface
Definition:
IInterface.h:237
Bootstrap.h
IProperty.h
ISvcLocator.h
Ensures
#define Ensures(a)
Definition:
GaudiEnv.h:26
GaudiTesting::GaudiEnv::m_propMgr
SmartIF< IProperty > m_propMgr
Definition:
GaudiEnv.h:62
ISvcManager.h
GaudiExamples
src
ToolVisitorTest
GaudiEnv.h
Generated on Fri Jul 28 2023 16:22:54 for The Gaudi Framework by
1.8.18