#include <opennurbs_md5.h>
|
static ON_MD5_Hash | BufferHash (const void *buffer, size_t sizeof_buffer) |
|
static int | Compare (const ON_MD5_Hash &a, const ON_MD5_Hash &b) |
|
static ON_MD5_Hash | FileHash (const wchar_t *filename, ON__UINT64 &sizeof_file) |
|
static ON_MD5_Hash | FileHash (const char *filename, ON__UINT64 &sizeof_file) |
|
static ON_MD5_Hash | FileHash (FILE *file, ON__UINT64 &sizeof_file) |
|
static ON_MD5_Hash | StringHash (const ON_wString &str, ON__UINT64 &byte_count) |
|
static ON_MD5_Hash | StringHash (const wchar_t *str, size_t str_length, ON__UINT64 &byte_count) |
|
static ON_MD5_Hash | StringHash (const ON_String &str, ON__UINT64 &byte_count) |
|
static ON_MD5_Hash | StringHash (const char *str, size_t str_length, ON__UINT64 &byte_count) |
|
◆ ON_MD5_Hash() [1/2]
ON_MD5_Hash::ON_MD5_Hash |
( |
| ) |
|
Default constructor is the zero digest hash.
◆ ~ON_MD5_Hash()
ON_MD5_Hash::~ON_MD5_Hash |
( |
| ) |
|
|
default |
◆ ON_MD5_Hash() [2/2]
◆ BufferHash()
static ON_MD5_Hash ON_MD5_Hash::BufferHash |
( |
const void * |
buffer, |
|
|
size_t |
sizeof_buffer |
|
) |
| |
|
static |
- Parameters
-
buffer | [in] |
sizeof_buffer | [in] number of bytes in buffer |
- Returns
- MD5 hash of the buffer.
◆ Compare()
◆ Dump()
void ON_MD5_Hash::Dump |
( |
class ON_TextLog & |
text_log | ) |
const |
◆ FileHash() [1/3]
static ON_MD5_Hash ON_MD5_Hash::FileHash |
( |
const wchar_t * |
filename, |
|
|
ON__UINT64 & |
sizeof_file |
|
) |
| |
|
static |
- Parameters
-
filename | [in] Name of file |
sizeof_file | [out] number of bytes in file |
- Returns
- MD5 hash of the buffer.
◆ FileHash() [2/3]
static ON_MD5_Hash ON_MD5_Hash::FileHash |
( |
const char * |
filename, |
|
|
ON__UINT64 & |
sizeof_file |
|
) |
| |
|
static |
◆ FileHash() [3/3]
static ON_MD5_Hash ON_MD5_Hash::FileHash |
( |
FILE * |
file, |
|
|
ON__UINT64 & |
sizeof_file |
|
) |
| |
|
static |
- Parameters
-
file | [in] File stream from ON_FileStream::Open(...,L"rb"); |
sizeof_file | [out] number of bytes in file |
- Returns
- MD5 hash of the file stream from the current offset to the end of the file.
◆ operator=()
◆ Read()
◆ StringHash() [1/4]
- Parameters
-
str | [in] string |
byte_count | [out] number of bytes in UTF-8 encoding of the string. |
- Returns
- MD5 hash of the UTF-8 encoding of the string. (Platforms and endian independent.)
◆ StringHash() [2/4]
static ON_MD5_Hash ON_MD5_Hash::StringHash |
( |
const wchar_t * |
str, |
|
|
size_t |
str_length, |
|
|
ON__UINT64 & |
byte_count |
|
) |
| |
|
static |
◆ StringHash() [3/4]
- Parameters
-
str | [in] |
byte_count | [out] number of bytes in the string. |
- Returns
- MD5 hash of the UTF-8 encoding of the string. (Platforms and endian independent.)
◆ StringHash() [4/4]
static ON_MD5_Hash ON_MD5_Hash::StringHash |
( |
const char * |
str, |
|
|
size_t |
str_length, |
|
|
ON__UINT64 & |
byte_count |
|
) |
| |
|
static |
◆ ToString()
const ON_wString ON_MD5_Hash::ToString |
( |
bool |
bUpperCaseHexadecimalDigits | ) |
const |
- Parameters
-
bUpperCaseHexadecimalDigits | [in] |
false | use 0-9, a-f |
true | use 0-9, A-F |
- Returns
- The MD5 hash value as a 32 hexadecimal digits. The first digit in the string is the hexadecimal value of m_digest[0].
◆ ToUTF8String()
const ON_String ON_MD5_Hash::ToUTF8String |
( |
bool |
bUpperCaseHexadecimalDigits | ) |
const |
- Parameters
-
bUpperCaseHexadecimalDigits | [in] |
false | use 0-9, a-f |
true | use 0-9, A-F |
- Returns
- The MD5 hash value as a 32 hexadecimal digits. The first digit in the string is the hexadecimal value of m_digest[0].
◆ Write()
◆ EmptyContentHash
◆ m_digest
ON__UINT8 ON_MD5_Hash::m_digest[16] |
◆ ZeroDigest