diff options
author | zyp <zyp@localhost> | 2006-05-09 22:33:27 +0200 |
---|---|---|
committer | zyp <zyp@localhost> | 2006-05-09 22:33:27 +0200 |
commit | 0c4fc1e72770fc78d87891e5c031272fca59e409 (patch) | |
tree | 10682cb815cff09ec1e2ce9beb619c916f08616c /src/ed2k.h | |
parent | 373495b3a1c8ccdcfece70bac69625b6823ccec0 (diff) |
[project @ zyp-20060509203327-c8c93b489da2ea46]
[project @ 27]
Multihash library rewrite complete.
Diffstat (limited to 'src/ed2k.h')
-rw-r--r-- | src/ed2k.h | 25 |
1 files changed, 15 insertions, 10 deletions
@@ -1,17 +1,22 @@ #ifndef _ED2K_H_ #define _ED2K_H_ +#include "hash.h" + #include <openssl/md4.h> -class Ed2k { - private: - MD4_CTX md4_partial; - MD4_CTX md4_final; - unsigned int size_total; - public: - Ed2k(); - void update(const char* data, int length); - char* digest(); -}; +namespace Multihash { + class Ed2k : public Hash { + private: + MD4_CTX md4_partial; + MD4_CTX md4_final; + unsigned int size_total; + protected: + virtual void hash_update(const char* data, int length); + virtual std::string hash_digest(); + public: + Ed2k(Hash* n = 0); + }; +} #endif // _ED2K_H_ |