1 #ifndef canvas_Persistency_Provenance_Hash_h 2 #define canvas_Persistency_Provenance_Hash_h 17 #include "cetlib/MD5Digest.h" 18 #include "cetlib/container_algorithms.h" 37 explicit Hash(value_type
const& v);
50 bool operator<(Hash<I>
const&
other)
const;
54 std::ostream& print(std::ostream& os)
const;
58 value_type compactForm()
const;
60 bool isCompactForm()
const;
72 void throwIfIllFormed()
const;
79 template <
typename Op>
84 return op(this->hash_, iOther.
hash_);
138 return this->
compareUsing(other, std::less<std::string>());
145 return this->
compareUsing(other, std::greater<std::string>());
152 return this->
compareUsing(other, std::equal_to<std::string>());
159 return this->
compareUsing(other, std::not_equal_to<std::string>());
168 cet::copy_all(tMe.
hash_, temp.bytes);
169 os << temp.toString();
198 if (
hash_.size() % 2 == 1) {
200 <<
"Ill-formed Hash instance. " 201 <<
"Please report this to the core framework developers";
212 switch (
hash_.size()) {
221 temp.fromHexifiedString(
hash_);
222 hash_ = temp.compactForm();
227 <<
"art::Hash<> instance with data in illegal state:\n" 228 <<
hash_ <<
"\nPlease report this to the core framework developers";
237 return 16 ==
hash_.size();
250 operator<<(std::ostream& os, Hash<I>
const& h)
std::string const & InvalidHash()
Hash< I > const & operator=(Hash< I > const &iRHS)
bool operator!=(Hash< I > const &other) const
bool operator>(Hash< I > const &other) const
bool operator!=(debugging_allocator< X > const &, debugging_allocator< Y > const &)
bool operator>(ScheduleID left, ScheduleID right)
void throwIfIllFormed() const
value_type compactForm() const
void swap(Handle< T > &a, Handle< T > &b)
bool operator==(Hash< I > const &other) const
bool isCompactForm() const
bool compareUsing(Hash< I > const &iOther, Op op) const
cet::coded_exception< errors::ErrorCodes, ExceptionDetail::translate > Exception
static short Class_Version()
bool operator<(Hash< I > const &other) const
std::ostream & print(std::ostream &os) const
bool operator==(Provenance const &a, Provenance const &b)
void swap(Hash< I > &other)