TESSerializer.h
Go to the documentation of this file.
1 // $Id: TESSerializer.h,v 1.1 2008/10/17 08:56:05 mato Exp $
2 #ifndef GAUDIMP_TESSERIALIZER_H
3 #define GAUDIMP_TESSERIALIZER_H
4 
5 #include "GaudiKernel/IDataStoreAgent.h"
6 #include "GaudiKernel/IAddressCreator.h"
7 
8 // ROOT includes
9 #include "TClass.h"
10 
11 // vector and string
12 #include <string>
13 #include <vector>
14 #include <map>
15 
16 // forward declarations
17 class IDataProviderSvc;
18 class IDataManagerSvc;
19 class TBufferFile;
20 class DataStoreItem;
21 class DataObject;
22 class IAddressCreator;
23 
31 namespace GaudiMP {
32  class GAUDI_API TESSerializer : virtual public IDataStoreAgent {
33  typedef std::vector<DataStoreItem*> Items;
34  typedef std::vector<std::string> ItemNames;
35  typedef std::vector<DataObject*> Objects;
36  public:
38  TESSerializer(IDataProviderSvc* svc, IAddressCreator* ac);
39 
41  void dumpBuffer(TBufferFile&);
42 
44  void loadBuffer(TBufferFile&);
45 
47  void addItem(const std::string& path);
48 
50  void addOptItem(const std::string& path);
51 
53  bool analyse(IRegistry* dir, int level);
54 
56  void checkItems( );
57 
58  virtual ~TESSerializer() {}
59 
60  protected:
62  void addItem(Items& itms, const std::string& descriptor);
63 
65  DataStoreItem* findItem(const std::string& path);
66 
67  private:
69  IDataProviderSvc* m_TES;
71  IDataManagerSvc* m_TESMgr;
73  ItemNames m_itemNames;
75  Items m_itemList;
77  ItemNames m_optItemNames;
79  Items m_optItemList;
81  DataStoreItem* m_currentItem;
83  Objects m_objects;
84 
86  std::map<std::string, TClass*> m_classMap;
88  bool m_verifyItems;
90  bool m_strict;
92  IAddressCreator* m_addressCreator;
93  };
94 }
95 #endif
96 
97 
Namespace for basic object handling within container classes.
Definition: KeyedObject.cpp:16
#define GAUDI_API
Definition: Kernel.h:108
A class to serialize/deserialize TES objects to and from a TBufferFile Author: P. ...
Definition: PyROOTPickle.h:32
list path
Definition: __init__.py:15
IAddressCreator interface definition.
Data provider interface definition.
Description of the DataStoreItem class.
Definition: DataStoreItem.h:18
The IRegistry represents the entry door to the environment any data object residing in a transient da...
Definition: IRegistry.h:22
Generic data agent interface.
list itms
Definition: ana.py:135
A DataObject is the base class of any identifiable object on any data store.
Definition: DataObject.h:31