Rust
Rust
Example: Crypt2.CrcBd method
Demonstrates how to call the CrcBd method.Chilkat Rust Downloads
let crypt = chilkat::Crypt2::new();
let bd = chilkat::BinData::new();
let _ = bd.append_string("123456789", "us-ascii");
let crc32 = crypt.crc_bd("crc-32", &bd);
// The decimal value is 3421780262 (converted to hex is 0xCBF43926)
println!("{}", crc32);
let crc8 = crypt.crc_bd("crc8", &bd);
println!("{}", crc8);