SlurpBlock() public method

Update the value for the running CRC32 using the given block of bytes. This is useful when using the CRC32() class in a Stream.
public SlurpBlock ( byte block, int offset, int count ) : void
block byte block of bytes to slurp
offset int starting point in the block
count int how many bytes within the block to slurp
return void
Beispiel #1
0
        public int Read()
        {
            if (Read(_buf1, 0, 1) == 0)
            {
                return(0);
            }

            // calculate CRC after reading
            if (crc != null)
            {
                crc.SlurpBlock(_buf1, 0, 1);
            }

            return(_buf1[0] & 0xFF);
        }