signinum-core 0.5.0

Shared decode contracts and types for signinum
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
// SPDX-License-Identifier: Apache-2.0

use crate::sample::Sample;

/// Destination for row-streaming decode output.
pub trait RowSink<S: Sample> {
    /// Error returned by the sink when it cannot accept a row.
    type Error: core::error::Error + Send + Sync + 'static;

    /// Write one decoded row at source/output row index `y`.
    fn write_row(&mut self, y: u32, row: &[S]) -> Result<(), Self::Error>;
}