pub trait PartitionBlocksSource:
Sync
+ Send
+ Debug {
// Required methods
fn is_empty(&self) -> bool;
fn get_nb_blocks(&self) -> i64;
fn get_max_payload_size(&self) -> i64;
fn get_source_data_hash(&self) -> Vec<u8> ⓘ;
fn get_blocks_stream<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Pin<Box<dyn Stream<Item = Result<Arc<PartitionSourceBlock>, Error>> + Send>>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
}Expand description
A trait for providing blocks of source data for partitions.
Required Methods§
Sourcefn get_nb_blocks(&self) -> i64
fn get_nb_blocks(&self) -> i64
Returns the number of blocks in the source.
Sourcefn get_max_payload_size(&self) -> i64
fn get_max_payload_size(&self) -> i64
Returns the maximum payload size of the blocks in the source.
Sourcefn get_source_data_hash(&self) -> Vec<u8> ⓘ
fn get_source_data_hash(&self) -> Vec<u8> ⓘ
Returns a hash of the source data.