### Compute CRC-64-ECMA checksum Source: https://docs.rs/crc64fast/1.1.0/crc64fast/index.html Demonstrates how to initialize a Digest, write data in chunks, and finalize the checksum calculation. ```rust use crc64fast::Digest; let mut c = Digest::new(); c.write(b"hello "); c.write(b"world!"); let checksum = c.sum64(); assert_eq!(checksum, 0x8483_c0fa_3260_7d61); ``` -------------------------------- ### Digest::new() Source: https://docs.rs/crc64fast Creates a new Digest instance to begin an in-progress CRC-64 computation. ```APIDOC ## Digest::new() ### Description Creates a new instance of the Digest struct to start a CRC-64-ECMA computation. ### Signature `pub fn new() -> Digest` ``` -------------------------------- ### Digest::new Source: https://docs.rs/crc64fast/1.1.0/crc64fast/index.html Creates a new Digest instance to begin a CRC-64-ECMA computation. ```APIDOC ## Digest::new ### Description Creates a new instance of the Digest struct to start an in-progress CRC-64 computation. ### Signature `pub fn new() -> Digest` ``` -------------------------------- ### Digest::new() Source: https://docs.rs/crc64fast/1.1.0/crc64fast/struct.Digest.html Creates a new Digest instance. It automatically performs runtime CPU feature detection to select the most efficient algorithm. ```APIDOC ## pub fn new() -> Self ### Description Creates a new `Digest` instance. It will perform runtime CPU feature detection to determine which algorithm to choose for optimal performance. ### Returns - **Self** - A new instance of the Digest struct. ``` -------------------------------- ### Digest::new_table() Source: https://docs.rs/crc64fast/1.1.0/crc64fast/struct.Digest.html Creates a new Digest instance specifically using the table-based algorithm. ```APIDOC ## pub fn new_table() -> Self ### Description Creates a new `Digest` instance using the table-based algorithm. ### Returns - **Self** - A new instance of the Digest struct. ``` -------------------------------- ### Digest::write() Source: https://docs.rs/crc64fast/1.1.0/crc64fast/struct.Digest.html Writes data into the digest to update the CRC-64 calculation. ```APIDOC ## pub fn write(&mut self, bytes: &[u8]) ### Description Writes some data into the digest to update the ongoing CRC-64 computation. ### Parameters - **bytes** (&[u8]) - The data to be processed by the digest. ``` -------------------------------- ### Digest::sum64() Source: https://docs.rs/crc64fast/1.1.0/crc64fast/struct.Digest.html Computes and returns the current CRC-64-ECMA value. ```APIDOC ## pub fn sum64(&self) -> u64 ### Description Computes the current CRC-64-ECMA value based on the data written so far. ### Returns - **u64** - The calculated CRC-64-ECMA value. ``` -------------------------------- ### Digest::sum64 Source: https://docs.rs/crc64fast/1.1.0/crc64fast/index.html Finalizes the computation and returns the resulting 64-bit CRC checksum. ```APIDOC ## Digest::sum64 ### Description Finalizes the current CRC-64 computation and returns the calculated checksum as a u64. ### Signature `pub fn sum64(&self) -> u64` ``` -------------------------------- ### Digest::write Source: https://docs.rs/crc64fast/1.1.0/crc64fast/index.html Updates the current CRC-64 computation with the provided byte slice. ```APIDOC ## Digest::write ### Description Updates the internal state of the Digest with the provided input bytes. ### Signature `pub fn write(&mut self, bytes: &[u8])` ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.