Implements calculation of the 32-bit CRC value for a block of data.
Parameters |
Description |
AStream |
Stream containing the data to be used for the CRC calculation. |
Word - 32-bit CRC value calculated from the input data.
HashValue is an overloaded LongWord function in TIdHashCRC32 that implements calculation of the 32-bit CRC value for a block of data.
HashValue is overridden in TIdHashCRC32 to implement the inherited method to use the pre-computed table of 32-bit CRC values for all 256 possible character combinations that can be represented by each byte in the input data.
HashValue calculates the CRC result by performing an exclusive OR for the current CRC value and the precomputed CRC value in the table for the low word of the current input data.
ABeginPos indicates the position of the initial byte value in AStream to be used when beginning the CRC calculation.
AEndPos indicates the the position of the final byte value in AStream to be used when beginning the CRC calculation. When EndPos is 0 (zero), remaining values starting at ABeginPos are used in the CRC calculation.
HashValue uses a 1024 byte buffer to read values from AStream, and calculates the CRC value for each byte in the buffer until all data in AStream has been processed.
Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved. Website http://www.indyproject.org. Post feedback to the Indy Documentation newsgroup. |