24 #ifndef INC_CRC64_HPP_D457DF18_2251_4074_831B_AE0C18F981FC
25 #define INC_CRC64_HPP_D457DF18_2251_4074_831B_AE0C18F981FC
69 void reset()
override;
85 std::string
toString(
const bool hexInUpperCase =
false)
const override;
95 uint8_t*
getValue(uint8_t* buffer)
const override;
112 void update(
const uint8_t* buf,
size_t len)
override;
170 return ChecksumAlgoId::CRC64;
Add some utilities to Checksum class.
Computes the CRC-64 (ECMA 182 standard) from a byte stream.
void reset() override
Resets the CRC64 to initial value.
ArrayString getAltNames() const override
Returns the alternative names of the CRC64 checksum algorithm.
static std::string getChecksumName()
Returns the name of the checksum algorithm.
uint8_t * getValue(uint8_t *buffer) const override
Returns the CRC64 value in the first 8 bytes of the given address.
CRC64()
Default constructor.
ChecksumAlgoId getID() const override
Returns an unique identifier for the checksum or the hash algorithm.
std::string toString(const bool hexInUpperCase=false) const override
Returns the CRC64 value in a string.
static Checksum * getNewInstance()
Gets a new instance of this class.
uint64_t getUint64Value() const
Returns the CRC64 value.
std::string getName() const override
Returns the name of the checksum or the hash algorithm.
void update(const uint8_t *buf, size_t len) override
Updates the CRC64 with specified array of bytes.
static ArrayString getAlternativeNames()
Returns the alternative names of the CRC64 checksum algorithm.
uint64_t crc64
The current CRC64 value.
static constexpr ChecksumAlgoId getIdentifier()
Returns an unique identifier for the checksum algorithm.
size_t getSize() const override
Returns the minimal size to allocate in memory to store the checksum with the getValue(buffer) metho...
static const uint64_t crc_table[256]
Table used to compute the CRC64 value.
Computes a hash from a byte stream.
Computes a checksum from a byte stream.
ChecksumAlgoId
Ids of algorithms of checksums.
std::vector< std::string > ArrayString
Array of strings.