[−][src]Struct crc_any::CRCu16
This struct can help you compute a CRC-16 (or CRC-x where x is under 16
) value.
Methods
impl CRCu16
[src]
pub fn create_crc(
poly: u16,
bits: u8,
initial: u16,
final_xor: u16,
reflect: bool
) -> CRCu16
[src]
poly: u16,
bits: u8,
initial: u16,
final_xor: u16,
reflect: bool
) -> CRCu16
Create a CRCu16
instance by providing the length of bits, expression, reflection, an initial value and a final xor value.
pub fn digest<T: ?Sized + AsRef<[u8]>>(&mut self, data: &T)
[src]
Digest some data.
pub fn reset(&mut self)
[src]
Reset the sum.
pub fn get_crc(&self) -> u16
[src]
Get the current CRC value (it always returns a u16
value). You can continue calling digest
method even after getting a CRC value.
impl CRCu16
[src]
pub fn get_crc_vec_le(&mut self) -> Vec<u8>
[src]
Get the current CRC value (it always returns a vec instance with a length corresponding to the CRC bits). You can continue calling digest
method even after getting a CRC value.
pub fn get_crc_vec_be(&mut self) -> Vec<u8>
[src]
Get the current CRC value (it always returns a vec instance with a length corresponding to the CRC bits). You can continue calling digest
method even after getting a CRC value.
impl CRCu16
[src]
pub fn crc10() -> CRCu16
[src]
pub fn crc10cdma2000() -> CRCu16
[src]
pub fn crc10gsm() -> CRCu16
[src]
pub fn crc11() -> CRCu16
[src]
pub fn crc12() -> CRCu16
[src]
pub fn crc12cdma2000() -> CRCu16
[src]
pub fn crc12gsm() -> CRCu16
[src]
pub fn crc13bbc() -> CRCu16
[src]
pub fn crc14darc() -> CRCu16
[src]
pub fn crc14gsm() -> CRCu16
[src]
pub fn crc15can() -> CRCu16
[src]
pub fn crc15mpt1327() -> CRCu16
[src]
pub fn crc16() -> CRCu16
[src]
pub fn crc16ccitt_false() -> CRCu16
[src]
pub fn crc16aug_ccitt() -> CRCu16
[src]
pub fn crc16buypass() -> CRCu16
[src]
pub fn crc16cdma2000() -> CRCu16
[src]
pub fn crc16dds_110() -> CRCu16
[src]
pub fn crc16dect_r() -> CRCu16
[src]
pub fn crc16dect_x() -> CRCu16
[src]
pub fn crc16dnp() -> CRCu16
[src]
pub fn crc16en_13757() -> CRCu16
[src]
pub fn crc16genibus() -> CRCu16
[src]
pub fn crc16maxim() -> CRCu16
[src]
pub fn crc16mcrf4cc() -> CRCu16
[src]
pub fn crc16riello() -> CRCu16
[src]
pub fn crc16t10_dif() -> CRCu16
[src]
pub fn crc16teledisk() -> CRCu16
[src]
pub fn crc16tms13157() -> CRCu16
[src]
pub fn crc16usb() -> CRCu16
[src]
pub fn crc_a() -> CRCu16
[src]
pub fn crc16kermit() -> CRCu16
[src]
pub fn crc16modbus() -> CRCu16
[src]
pub fn crc16_x25() -> CRCu16
[src]
pub fn crc16xmodem() -> CRCu16
[src]
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,