CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
FileID.h
Go to the documentation of this file.
1 #ifndef DataFormats_Provenance_FileID_h
2 #define DataFormats_Provenance_FileID_h
3 
4 /*----------------------------------------------------------------------
5 
6 Holds a unique file identifier in string form.
7 
8 ----------------------------------------------------------------------*/
9 
10 #include <string>
11 
12 namespace edm {
13 
14  class FileID {
15  public:
16  FileID() : fid_() {}
17  explicit FileID(std::string const& id) : fid_(id) {}
18  bool isValid() const { return !fid().empty(); }
19  std::string const& fid() const { return fid_; }
20 
21  private:
23  };
24 
25  inline bool operator==(FileID const& lh, FileID const& rh) { return lh.fid() == rh.fid(); }
26 
27  inline bool operator!=(FileID const& lh, FileID const& rh) { return !(lh == rh); }
28 
29  std::ostream& operator<<(std::ostream& os, FileID const& id);
30 } // namespace edm
31 #endif
constexpr bool operator==(ELseverityLevel const &e1, ELseverityLevel const &e2) noexcept
FileID(std::string const &id)
Definition: FileID.h:17
bool int lh
Definition: SIMDVec.h:20
std::string fid_
Definition: FileID.h:22
std::string const & fid() const
Definition: FileID.h:19
bool isValid() const
Definition: FileID.h:18
constexpr bool operator!=(ELseverityLevel const &e1, ELseverityLevel const &e2) noexcept
std::ostream & operator<<(std::ostream &ost, const HLTGlobalStatus &hlt)
Formatted printout of trigger tbale.
FileID()
Definition: FileID.h:16