A streaming stateful decoder that accumulates symbols as they arrive and attempts to decode once enough symbols are available.
Example
state = Raptorq.StreamingDecoder.new(10, 40)
{:ok, :incomplete, state} = Raptorq.StreamingDecoder.add_symbol(state, 0, sym0)
# ... accumulate more symbols ...
{:ok, {:decoded, data}, state} = Raptorq.StreamingDecoder.add_symbol(state, 12, sym12)
Summary
Functions
Add a symbol to the decoder state.
Initialize a new streaming decoder for a block of k source symbols.
data_size is optional and used to truncate padding from the final output.
Functions
Add a symbol to the decoder state.
Returns {:ok, :incomplete, state} if more symbols are needed (or if the
system remains singular).
Returns {:ok, {:decoded, binary}, state} if the data was successfully recovered.
Returns {:error, reason, state} if the symbol is invalid (e.g. inconsistent size).
Initialize a new streaming decoder for a block of k source symbols.
data_size is optional and used to truncate padding from the final output.