Skip to main content

Module codec

Module codec 

Source
Expand description

§Delta Encoder/Decoder

This module provides functionality for delta encoding and decoding, a technique used to efficiently transmit log data by sending only the differences between consecutive versions of a document. This reduces the amount of data that needs to be sent over the network, improving performance in log transmission scenarios.

Enums§

Frame
Represents a data frame, which can be either a full snapshot or a differential update.

Constants§

TAG_DIFF
Tag for a differential frame, representing the changes since the last version.
TAG_FULL
Tag for a full frame, indicating a complete snapshot of a document.

Functions§

decode
Decodes a byte slice into a Frame.
encode_diff
Encodes a differential update into a byte vector.
encode_full
Encodes a full token set into a byte vector.