Project
Loading...
Searching...
No Matches
ObjectCache.h
Go to the documentation of this file.
1
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
#ifndef O2_FRAMEWORK_OBJECTCACHE_H_
12
#define O2_FRAMEWORK_OBJECTCACHE_H_
13
14
#include "
Framework/DataRef.h
"
15
#include <unordered_map>
16
#include <map>
17
#include <string>
18
19
namespace
o2::framework
20
{
21
25
struct
ObjectCache
{
26
struct
Id
{
27
int64_t
value
;
28
static
Id
fromRef
(
DataRef
&
ref
)
29
{
30
return
{
reinterpret_cast<
int64_t
>
(
ref
.payload)};
31
}
32
bool
operator==
(
const
Id
&
other
)
const
33
{
34
return
value
==
other
.value;
35
}
36
37
struct
hash_fn
{
38
std::size_t
operator()
(
const
Id
&
id
)
const
39
{
40
return
id
.value;
41
}
42
};
43
};
44
46
struct
Entry
{
47
Id
id
{0};
48
void
*
obj
{
nullptr
};
49
};
50
52
struct
MetadataEntry
{
53
Id
id
{0};
54
std::map<std::string, std::string>
metadata
;
55
};
56
60
std::unordered_map<std::string, Entry>
matcherToEntry
;
61
65
std::unordered_map<std::string, MetadataEntry>
matcherToMetadata
;
66
};
67
68
}
// namespace o2::framework
69
70
#endif
// O2_FRAMEWORK_OBJECTCACHE_H_
DataRef.h
int64_t
int
value
GLsizei const GLfloat * value
Definition
glcorearb.h:819
o2::framework
Defining ITS Vertex explicitly as messageable.
Definition
Cartesian.h:288
o2::framework::DataRef
Definition
DataRef.h:24
o2::framework::ObjectCache::Entry
Per-path cache entry for a deserialised CCDB object.
Definition
ObjectCache.h:46
o2::framework::ObjectCache::Entry::obj
void * obj
Definition
ObjectCache.h:48
o2::framework::ObjectCache::Id::hash_fn
Definition
ObjectCache.h:37
o2::framework::ObjectCache::Id::hash_fn::operator()
std::size_t operator()(const Id &id) const
Definition
ObjectCache.h:38
o2::framework::ObjectCache::Id
Definition
ObjectCache.h:26
o2::framework::ObjectCache::Id::fromRef
static Id fromRef(DataRef &ref)
Definition
ObjectCache.h:28
o2::framework::ObjectCache::Id::value
int64_t value
Definition
ObjectCache.h:27
o2::framework::ObjectCache::Id::operator==
bool operator==(const Id &other) const
Definition
ObjectCache.h:32
o2::framework::ObjectCache::MetadataEntry
Per-path cache entry for the CCDB metadata map.
Definition
ObjectCache.h:52
o2::framework::ObjectCache::MetadataEntry::metadata
std::map< std::string, std::string > metadata
Definition
ObjectCache.h:54
o2::framework::ObjectCache
Definition
ObjectCache.h:25
o2::framework::ObjectCache::matcherToEntry
std::unordered_map< std::string, Entry > matcherToEntry
Definition
ObjectCache.h:60
o2::framework::ObjectCache::matcherToMetadata
std::unordered_map< std::string, MetadataEntry > matcherToMetadata
Definition
ObjectCache.h:65
other
VectorOfTObjectPtrs other
Definition
test_Algorithm.cxx:525
Framework
Core
include
Framework
ObjectCache.h
Generated on Fri Jun 26 2026 13:47:29 for Project by
1.9.8