ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Reconstruction
EventShapes
EventShapeEvent
src
EventFeatureStore.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
6
#include "
EventShapeEvent/EventFeatureStore.h
"
7
8
//EventFeature EventFeatureStore::m_invalidConstReference = EventFeature();
9
//EventFeature EventFeatureStore::m_invalidReference = EventFeature();
10
11
12
EventFeatureStore::EventFeatureStore
(
SG::OwnershipPolicy
own)
13
:
DataVector
<
EventFeature
>(own)
14
{ }
15
16
EventFeatureStore::~EventFeatureStore
()
17
{ }
18
19
bool
EventFeatureStore::retrieve
(
EventFeature::FeatureType
type
,
20
const
std::string& tag,
21
const
EventFeature
* &pFeature)
const
22
{
23
const_iterator
fFeat(this->
find
(type,tag));
24
if
( fFeat != this->
end
() )
25
{
26
pFeature = *fFeat;
27
return
true
;
28
}
29
return
false
;
30
}
31
32
bool
EventFeatureStore::retrieve
(
EventFeature::FeatureType
type
,
33
const
std::string& tag,
34
EventFeature
* &pFeature)
35
{
36
iterator
fFeat(this->
find
(type,tag));
37
if
( fFeat != this->
end
() )
38
{
39
pFeature = *fFeat;
40
return
true
;
41
}
42
return
false
;
43
}
44
45
EventFeatureStore::iterator
EventFeatureStore::find
(
EventFeature::FeatureType
46
type
,
47
const
std::string& tag)
48
{
49
iterator
fFeat(this->
begin
());
50
iterator
lFeat(this->
end
());
51
while
( fFeat != lFeat && (
type
!= (*fFeat)->
type
() ||
52
tag != (*fFeat)->tag() ) )
53
{ ++fFeat; }
54
return
fFeat;
55
}
56
57
EventFeatureStore::const_iterator
58
EventFeatureStore::find
(
EventFeature::FeatureType
type
,
59
const
std::string& tag)
const
60
{
61
const_iterator
fFeat(this->
begin
());
62
const_iterator
lFeat(this->
end
());
63
while
( fFeat != lFeat && (
type
!= (*fFeat)->
type
() ||
64
tag != (*fFeat)->tag() ) )
65
{ ++fFeat; }
66
return
fFeat;
67
}
68
69
EventFeatureStore::iterator
EventFeatureStore::find
(
EventFeature
* pFeature)
70
{
71
iterator
fFeat(this->
begin
());
72
iterator
lFeat(this->
end
());
73
while
( fFeat != lFeat && (*fFeat) != pFeature ) { ++fFeat; }
74
return
fFeat;
75
}
76
77
EventFeatureStore::const_iterator
78
EventFeatureStore::find
(
const
EventFeature
* pFeature)
const
79
{
80
const_iterator
fFeat(this->
begin
());
81
const_iterator
lFeat(this->
end
());
82
while
( fFeat != lFeat && (*fFeat) != pFeature ) { ++fFeat; }
83
return
fFeat;
84
}
EventFeatureStore.h
DataVector< EventFeature >::const_iterator
DataModel_detail::const_iterator< DataVector > const_iterator
Definition
DataVector.h:838
DataVector< EventFeature >::iterator
DataModel_detail::iterator< DataVector > iterator
Definition
DataVector.h:842
DataVector< EventFeature >::DataVector
DataVector(SG::OwnershipPolicy ownPolicy=SG::OWN_ELEMENTS, SG::IndexTrackingPolicy trackIndices=SG::DEFAULT_TRACK_INDICES)
DataVector< EventFeature >::end
const_iterator end() const noexcept
DataVector< EventFeature >::begin
const_iterator begin() const noexcept
EventFeatureStore::~EventFeatureStore
virtual ~EventFeatureStore()
Baseclass destructor.
Definition
EventFeatureStore.cxx:16
EventFeatureStore::retrieve
virtual bool retrieve(EventFeature::FeatureType type, const std::string &tag, const EventFeature *&pFeature) const
Retrieve method for EventFeature (const retrieve).
Definition
EventFeatureStore.cxx:19
EventFeatureStore::EventFeatureStore
EventFeatureStore(SG::OwnershipPolicy own=SG::OWN_ELEMENTS)
Standard DataVector constructor.
Definition
EventFeatureStore.cxx:12
EventFeatureStore::find
virtual const_iterator find(EventFeature::FeatureType type, const std::string &tag) const
Find EventFeature by identifiers (const access).
Definition
EventFeatureStore.cxx:58
EventFeature
Basic container for event feature data.
Definition
EventFeature.h:18
EventFeature::FeatureType
FeatureType
@
Definition
EventFeature.h:24
SG::OwnershipPolicy
OwnershipPolicy
Definition
OwnershipPolicy.h:16
type
GeneratePersELinkType_p1::type
ElementLink_p1< typename GenerateELinkIndexType_p1< typename LINK::index_type >::type > type
Definition
ElementLink_p1.h:82
Generated on
for ATLAS Offline Software by
1.17.0