ProductID.cc
Go to the documentation of this file.
2 #include "cetlib/crc32.h"
3 
4 #include <ostream>
5 
6 namespace art {
7 
9  : ProductID{toID(canonicalProductName)}
10  {}
11 
12  void
14  {
15  value_ = toID(canonicalProductName);
16  }
17 
20  {
21  return cet::crc32{canonicalProductName}.digest();
22  }
23 
24  std::ostream&
25  operator<<(std::ostream& os, ProductID const id)
26  {
27  os << id.value();
28  return os;
29  }
30 }
std::string string
Definition: nybbler.cc:12
constexpr ProductID()=default
std::ostream & operator<<(std::ostream &os, const GroupSelector &gs)
unsigned int value_type
Definition: ProductID.h:17
std::string canonicalProductName(std::string const &friendlyClassName, std::string const &moduleLabel, std::string const &productInstanceName, std::string const &processName)
void setID(std::string const &canonicalProductName)
Definition: ProductID.cc:13
static value_type toID(std::string const &branchName)
Definition: ProductID.cc:19
value_type value_
Definition: ProductID.h:86
constexpr digest_t digest() const
Definition: crc32.h:138