ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Database
AthenaPOOL
RootConversions
src
VectorConverters.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
// $Id$
14
15
16
#include "
RootConversions/VectorConverters.h
"
17
#include "
RootConversions/VectorConverter.h
"
18
#include "
RootConversions/TConverterRegistry.h
"
19
20
#ifdef XAOD_ANALYSIS
21
#include "TError.h"
22
#endif
23
24
25
namespace
RootConversions
{
26
27
31
void
VectorConverters::initialize
()
32
{
33
#ifdef XAOD_ANALYSIS
34
// initialize() is called once during single-threaded job setup.
35
long
tmpError = gErrorIgnoreLevel;
36
gErrorIgnoreLevel = kError;
//silences warnings about duplicate entries from vector.dll and vector-bool.dll
37
#endif
38
TConverterRegistry::Instance
()->
AddStreamerConverter
39
(
"vector<double>"
,
"vector<float>"
,
40
new
RootConversions::VectorConverter<double,float>
(
"double"
));
41
42
TConverterRegistry::Instance
()->
AddStreamerConverter
43
(
"vector<unsigned long>"
,
"vector<unsigned long long>"
,
44
new
RootConversions::VectorConverter<unsigned long,unsigned long long>
45
(
"unsigned long"
));
46
47
TConverterRegistry::Instance
()->
AddStreamerConverter
48
(
"vector<unsigned long long>"
,
"vector<unsigned long>"
,
49
new
RootConversions::VectorConverter<unsigned long long,unsigned long>
50
(
"unsigned long long"
));
51
52
TConverterRegistry::Instance
()->
AddStreamerConverter
53
(
"vector<unsigned short>"
,
"vector<int>"
,
54
new
RootConversions::VectorConverter<unsigned short,int>
55
(
"unsigned short"
));
56
57
TConverterRegistry::Instance
()->
AddStreamerConverter
58
(
"vector<unsigned short>"
,
"vector<long long>"
,
59
new
RootConversions::VectorConverter<unsigned short,long long>
60
(
"unsigned short"
));
61
62
TConverterRegistry::Instance
()->
AddStreamerConverter
63
(
"vector<unsigned short>"
,
"vector<Long64_t>"
,
64
new
RootConversions::VectorConverter<unsigned short,Long64_t>
65
(
"unsigned short"
));
66
67
TConverterRegistry::Instance
()->
AddStreamerConverter
68
(
"vector<unsigned int>"
,
"vector<ULong64_t>"
,
69
new
RootConversions::VectorConverter<unsigned int,ULong64_t>
70
(
"unsigned int"
));
71
#ifdef XAOD_ANALYSIS
72
gErrorIgnoreLevel = tmpError;
73
#endif
74
}
75
76
77
}
// namespace RootConversions
TConverterRegistry.h
Registry for Root converters.
VectorConverter.h
Template for streamer converter for vector<T> -> vector, assuming T is convertable to U.
VectorConverters.h
Define converters for some standard vector types, needed to read old data files and for cross-platfor...
RootConversions::VectorConverter
Converter for vector<T> to vector.
Definition
VectorConverter.h:37
RootConversions::VectorConverters::initialize
static void initialize()
Register all CLHEP converters.
Definition
VectorConverters.cxx:31
TConverterRegistry::Instance
static TConverterRegistry * Instance()
Return a pointer to the global registry instance.
Definition
TConverterRegistry.cxx:142
TConverterRegistry::AddStreamerConverter
void AddStreamerConverter(const std::string &from_type, const std::string &to_type, TMemberStreamer *streamer)
Definition
TConverterRegistry.cxx:113
RootConversions
Definition
VectorConverter.h:28
Generated on
for ATLAS Offline Software by
1.17.0