ATLAS Offline Software
Loading...
Searching...
No Matches
TrigTSerializer.h
Go to the documentation of this file.
1// -*- C++ -*-
2
3/*
4 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
5*/
6
7
12
13
14#ifndef TRIGTSERIALIZER_H
15#define TRIGTSERIALIZER_H
16
17#include "Gaudi/Property.h"
21#include "Rtypes.h"
22#include "TError.h"
23#include <string>
24#include <map>
25
26//forward decl
27class TBuffer;
28class TList;
29class MsgStream;
30
32typedef RootType Type;
34
35
37public:
38 TrigTSerializer(const std::string& name, const std::string& type,
39 const IInterface* parent);
40 virtual ~TrigTSerializer();
41
42 StatusCode initialize();
43 StatusCode finalize();
44
45 std::vector<uint32_t> serialize(const std::string &nameOfClass, const void* instance);
46
47 void serialize(const std::string &nameOfClass, const void* instance, std::vector<uint32_t> &v);
48
49 void* deserialize(const std::string &nameOfClass, const std::vector<uint32_t>& v);
50
51 StatusCode initClass(const std::string &nameOfClass) const;
52
53 //reset Serializer internal data between running serialize methods with unrelated data
54 void reset();
55
56 StatusCode peekCLID(const std::vector<uint32_t>& v, uint32_t *guid) const;
57
58 void setCLID(const uint32_t *guid);
59
60private:
61 void do_persistify(const std::string& nameOfClass, void* instance);
62 void do_persistify_obj(const std::string& nameOfClass, void* instance);
63 void do_follow_ptr(const std::string& nameOfClass, void* instance);
65
66 static bool streamerErrorHandler(Int_t level, Bool_t abort_bool,
67 const char* location, const char *msg);
68 static bool bsDictWarningFilter(Int_t level, Bool_t abort_bool,
69 const char* location, const char *msg);
70
71 void prepareForTBuffer(const std::string &nameOfClass);
72 void restoreAfterTBuffer(const std::string &nameOfClass);
73
75 uint32_t m_guid[4];
76
77 // for error handling
78 static bool s_decodingError;
79 uint32_t m_IgnoreErrLvl{};
80 std::map<std::string, uint32_t> m_errCount;
81
83 StringArrayProperty m_ignoreMissingDicts {
84 this, "IgnoreMissingDicts", {},
85 "Suppress warining about missing dictionaries", "OrderedSet<std::string>" };
86
87 static std::vector<std::string> s_dictsToIgnore;
88
91};
92
93#undef REFLEX_NS
94
95
96#endif
TMemberAdapter RootDataMember
Definition RootType.h:208
TTypeAdapter RootType
Definition RootType.h:211
std::map< std::string, double > instance
RootDataMember Member
Define macros for attributes used to control the static checker.
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters:
MsgStream & msg() const
AlgTool interface of a serializer implementation.
virtual StatusCode initClass(const std::string &nameOfClass) const =0
initialize framework to be ready to serialize a given class method to be called to prevent delayed in...
virtual StatusCode peekCLID(const std::vector< uint32_t > &v, uint32_t *guid) const =0
access clid of the payload (stored in BS)
virtual void reset()=0
clean internal serializer state.
virtual void serialize(const std::string &nameOfClass, const void *instance, std::vector< uint32_t > &v)=0
serializes an object of a class nameOfClass pointed to by instance and recursively also other objects...
virtual void * deserialize(const std::string &nameOfClass, const std::vector< uint32_t > &v)=0
deserializes an object of a class nameOfClass (and recursively other objects) found in std::vector<ui...
virtual void setCLID(const uint32_t *guid)=0
access clid of the payload virtual CLID getCLID() const = 0;
uint32_t m_IgnoreErrLvl
StatusCode finalize()
TList * m_streamersList
Remember streamer info list for cleaning up later.
StringArrayProperty m_ignoreMissingDicts
IgnoreMissingDicts.
static bool s_decodingError
void add_previous_streamerinfos()
static bool bsDictWarningFilter(Int_t level, Bool_t abort_bool, const char *location, const char *msg)
std::map< std::string, uint32_t > m_errCount
void restoreAfterTBuffer(const std::string &nameOfClass)
void prepareForTBuffer(const std::string &nameOfClass)
void do_persistify(const std::string &nameOfClass, void *instance)
void do_persistify_obj(const std::string &nameOfClass, void *instance)
uint32_t m_guid[4]
static bool streamerErrorHandler(Int_t level, Bool_t abort_bool, const char *location, const char *msg)
TrigTSerializer(const std::string &name, const std::string &type, const IInterface *parent)
void do_follow_ptr(const std::string &nameOfClass, void *instance)
void initialize()