ATLAS Offline Software
ITagInfoMgr.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef EVENTINFOMGT_ITAGINFOMGR_H
6 # define EVENTINFOMGT_ITAGINFOMGR_H
7 
16 //<<<<<< INCLUDES >>>>>>
17 
18 #include "GaudiKernel/Service.h"
19 
20 class MsgStream;
21 
22 //<<<<<< CLASS DECLARATIONS >>>>>>
23 
57 class ITagInfoMgr : virtual public IInterface
58 {
59 public:
61 
62  typedef std::pair<std::string, std::string> NameTagPair;
63  typedef std::vector<NameTagPair> NameTagPairVec;
65 
66 
69  class Listener {
70  public:
71  virtual void tagInfoUpdated() = 0;
72  };
73 
75  virtual void addListener(Listener* listener) = 0;
76 
78  virtual void removeListener(Listener* listener) = 0;
79 
80 
82  static const InterfaceID& interfaceID();
83 
85  virtual StatusCode addTag(const std::string& tagName,
86  const std::string& tagValue) = 0;
87 
90  virtual StatusCode removeTagFromInput(const std::string& tagName) = 0;
91 
93  virtual std::string findTag(const std::string & name) const = 0;
94 
96  virtual std::string findInputTag(const std::string& name) const = 0;
97 
99  virtual NameTagPairVec getInputTags() const = 0;
100 
102  virtual std::string dumpTagInfoToStr() const = 0;
103 
105  virtual void printTags(MsgStream& log) const = 0;
106 };
107 
108 
109 //<<<<<< INLINE PUBLIC FUNCTIONS >>>>>>
110 //<<<<<< INLINE MEMBER FUNCTIONS >>>>>>
111 
112 inline const InterfaceID&
114 {
115  static const InterfaceID IID_ITagInfoMgr("ITagInfoMgr", 1 , 0);
116  return IID_ITagInfoMgr;
117 }
118 
119 #endif // EVENTINFOMGT_ITAGINFOMGR_H
ITagInfoMgr::findTag
virtual std::string findTag(const std::string &name) const =0
Find tag by its name, return by value - empty string if not found.
ITagInfoMgr::removeTagFromInput
virtual StatusCode removeTagFromInput(const std::string &tagName)=0
Method to allow clients to remove a tag which may have come in on the input.
ITagInfoMgr::addTag
virtual StatusCode addTag(const std::string &tagName, const std::string &tagValue)=0
Method to allow clients to add in tags as: tag name, tag value.
ITagInfoMgr::Listener::tagInfoUpdated
virtual void tagInfoUpdated()=0
ITagInfoMgr::Listener
Listener interface class that client who want to be notified about TagInfo update should implement (a...
Definition: ITagInfoMgr.h:69
ITagInfoMgr::NameTagPairVec
std::vector< NameTagPair > NameTagPairVec
Definition: ITagInfoMgr.h:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ITagInfoMgr::addListener
virtual void addListener(Listener *listener)=0
Add a Listener to the notification list for TagInfo changes.
ITagInfoMgr::NameTagPair
std::pair< std::string, std::string > NameTagPair
Definition: ITagInfoMgr.h:62
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
ITagInfoMgr::printTags
virtual void printTags(MsgStream &log) const =0
Printout method.
ITagInfoMgr::interfaceID
static const InterfaceID & interfaceID()
Retrieve interface ID.
Definition: ITagInfoMgr.h:113
ITagInfoMgr::removeListener
virtual void removeListener(Listener *listener)=0
Remove a Listener from the notification list for TagInfo changes.
ITagInfoMgr::findInputTag
virtual std::string findInputTag(const std::string &name) const =0
Find INPUT tag by its name, return by value - empty string if not found.
ITagInfoMgr
This is a Athena service which manages detector description tag information. It maintains a TagInfo o...
Definition: ITagInfoMgr.h:58
ITagInfoMgr::getInputTags
virtual NameTagPairVec getInputTags() const =0
Return a vector with all current input tags.
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
ITagInfoMgr::dumpTagInfoToStr
virtual std::string dumpTagInfoToStr() const =0
Dump the content of the current TagInfo to std::string for debug.