10#ifndef SEMF_APP_PROCESSING_CRC_H_
11#define SEMF_APP_PROCESSING_CRC_H_
43 virtual const uint8_t*
accumulate(
const uint8_t data[],
size_t size) = 0;
52 virtual const uint8_t*
calculate(
const uint8_t data[],
size_t size) = 0;
58 virtual bool isEqual(
const uint8_t data[]) = 0;
Interface for implementing cyclic redundancy check (CRC).
virtual bool isEqual(const uint8_t data[])=0
Checks if previously calculated CRC is equal to the input value.
virtual const uint8_t * accumulate(const uint8_t data[], size_t size)=0
Computes the CRC of the input data using a combination of the previous CRC value and the new one.
virtual void reset()=0
Resets internal values to their initial values.
virtual const uint8_t * calculate(const uint8_t data[], size_t size)=0
Calculates the CRC of the input data.
virtual size_t bitSize() const =0
Returns the size of the CRC in bits.
virtual size_t byteSize() const =0
Returns the size of the CRC in bytes.