#include <Digest.h>
Public Member Functions | |
std::string | compactForm () const |
void | fromHexifiedString (std::string const &s) |
bool | isValid () const |
MD5Result () | |
std::string | toString () const |
Public Attributes | |
unsigned char | bytes [16] |
cms::MD5Result::MD5Result | ( | ) |
Definition at line 64 of file Digest.cc.
References cms::set_to_default().
{ set_to_default(*this); }
std::string cms::MD5Result::compactForm | ( | ) | const |
Definition at line 102 of file Digest.cc.
References bytes, AlCaHLTBitMon_ParallelJobs::p, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by edm::hash_detail::fixup_(), and edm::detail::InvalidHash().
{ // This is somewhat dangerous, because the conversion of 'unsigned // char' to 'char' may be undefined if 'char' is a signed type // (4.7p3 in the Standard). const char* p = reinterpret_cast<const char*>(&bytes[0]); return std::string(p, p+sizeof(bytes)); }
void cms::MD5Result::fromHexifiedString | ( | std::string const & | s | ) |
Definition at line 111 of file Digest.cc.
References bytes, Exception, i, edm::errors::LogicError, and cms::set_to_default().
Referenced by edm::hash_detail::fixup_().
{ switch (hexy.size()) { case 0: { set_to_default(*this); } break; case 32: { std::string::const_iterator it = hexy.begin(); for (size_t i = 0; i != 16; ++i) { // first nybble bytes[i] = ( unhexify(*it++) << 4 ); // second nybble bytes[i] += ( unhexify(*it++) ); } } break; default: { // Not really sure of what sort of exception to throw... throw edm::Exception(edm::errors::LogicError) << "String of illegal length: " << hexy.size() << " given to MD5Result::fromHexifiedString"; } } }
bool cms::MD5Result::isValid | ( | void | ) | const |
std::string cms::MD5Result::toString | ( | ) | const |
Definition at line 87 of file Digest.cc.
References bytes, i, AlCaHLTBitMon_ParallelJobs::p, cms::s_hexValues, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by dumpInitHeader(), cms::operator<<(), edm::hash_detail::print_(), edm::hash_detail::toDigest_(), and edm::hash_detail::toString_().
unsigned char cms::MD5Result::bytes[16] |
Definition at line 21 of file Digest.h.
Referenced by compactForm(), cms::Digest::digest(), fromHexifiedString(), cms::operator<(), cms::operator==(), edm::hash_detail::print_(), cms::set_to_default(), edm::hash_detail::toDigest_(), toString(), and edm::hash_detail::toString_().