RPNX::Compress
Self-contained C++20 compression and ZIP library
 
Loading...
Searching...
No Matches
rpnx::compression::implementation::adler32_accumulator Class Reference

Incremental Adler-32 accumulator. More...

#include <io.hpp>

Public Member Functions

void update (std::byte value) noexcept
 Includes one byte in the checksum.
 
std::uint32_t value () const noexcept
 Returns the checksum for all bytes supplied so far.
 

Detailed Description

Incremental Adler-32 accumulator.

Definition at line 199 of file io.hpp.

Member Function Documentation

◆ update()

void rpnx::compression::implementation::adler32_accumulator::update ( std::byte value)
inlinenoexcept

Includes one byte in the checksum.

Parameters
valueNext byte in stream order.

Definition at line 206 of file io.hpp.

References value().

Referenced by rpnx::compression::deflate_codec::compress(), and rpnx::compression::deflate_codec::decompress().

◆ value()

std::uint32_t rpnx::compression::implementation::adler32_accumulator::value ( ) const
inlinenodiscardnoexcept

Returns the checksum for all bytes supplied so far.

Returns
Adler-32 value with the second sum in the high 16 bits.

Definition at line 217 of file io.hpp.

Referenced by rpnx::compression::deflate_codec::compress(), rpnx::compression::deflate_codec::decompress(), and update().


The documentation for this class was generated from the following file: