mirror of https://github.com/aria2/aria2
2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Updated doc. * src/MessageDigestHelper.h:pull/1/head
parent
ebd524b6a2
commit
b7e841e885
|
@ -1,3 +1,8 @@
|
|||
2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||
|
||||
Updated doc.
|
||||
* src/MessageDigestHelper.h:
|
||||
|
||||
2008-02-18 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
|
||||
|
||||
Use raw message digest as a token instead of its hexadecimal
|
||||
|
|
|
@ -46,16 +46,11 @@ class BinaryStream;
|
|||
class MessageDigestHelper {
|
||||
public:
|
||||
/**
|
||||
* Returns message digest in hexadecimal notation.
|
||||
* Returns message digest in hexadecimal representation.
|
||||
* Digest algorithm is specified by algo.
|
||||
*/
|
||||
static std::string digest(const std::string& algo, const SharedHandle<BinaryStream>& bs, int64_t offset, int64_t length);
|
||||
|
||||
/**
|
||||
* Calculates message digest of file denoted by filename.
|
||||
*/
|
||||
static std::string digest(const std::string& algo, const std::string& filename);
|
||||
|
||||
static std::string digest(const std::string& algo, const void* data, int32_t length);
|
||||
|
||||
static std::string digestString(const std::string& algo, const std::string& data)
|
||||
|
@ -63,6 +58,13 @@ public:
|
|||
return digest(algo, data.c_str(), data.size());
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculates message digest of file denoted by filename.
|
||||
* Returns message digest in hexadecimal representation.
|
||||
* Digest algorithm is specified by algo.
|
||||
*/
|
||||
static std::string digest(const std::string& algo, const std::string& filename);
|
||||
|
||||
/**
|
||||
* Stores *raw* message digest into md.
|
||||
* Throws exception when mdLength is less than the size of message digest.
|
||||
|
|
Loading…
Reference in New Issue