This is a new site that's currently running on alpha code. There are going to be bugs. If you discover any, please report them on the site's issues page (GitHub account required). Thanks.
Warning: Many URLs are going to change. Refer to the README file to discover which library project's documentation has been completed.
Project: MD5 Message Digest Unit
Applies to: ~>1.0
Resets the TPJMD5 object and discards the current digest ready to calculate a new hash. Calling this method sets the object to its newly created state.
The method sets the Finalized property to
Suppose you need two get two MD5 hashes using the same TPJMD5 instance. The following code will do it:
var MD5: TPJMD5; begin MD5 := TPJMD5.Create; try MD5.Process('Foo', TEncoding.ASCII); ShowMessage(MD5.Digest); // implicitly casts Digest to string MD5.Reset; MD5.Process('Bar', TEncoding.ASCII); ShowMessage(MD5.Digest); // implicitly casts Digest to string finally MD5.Free; end; end;