pub fn filtered_chunks<F, C>(
        &self,
        partition_key: Option<&str>,
        table_names: TableNameFilter<'_>,
        map: F,
    ) -> Vec<C>
    where
        F: Fn(&Chunk) -> C + Copy,
    {
        let mut chunks = Vec::new();
        let partitions = self.partitions.read();

        let partitions = match partition_key {
            None => itertools::Either::Left(partitions.values()),
            Some(partition_key) => {
                itertools::Either::Right(partitions.get(partition_key).into_iter())
            }
        };

        for partition in partitions {
            let partition = partition.read();
            chunks.extend(partition.filtered_chunks(table_names).map(|chunk| {
                let chunk = chunk.read();
                map(&chunk)
            }))
        }
        chunks
    }
/// Calls `map` with every chunk and returns a collection of the results
///
/// If `partition_key` is Some(partition_key) only returns chunks
/// from the specified partiton.
///
/// `table_names` specifies which tables to include
Calls `map` with every chunk and returns a collection of the results
If `partition_key` is Some(partition_key) only returns chunks
from the specified partiton.

`table_names` specifies which tables to include
Calls ` map ` with every chunk and returns a collection of the results If ` partition_key ` is Some ( partition_key ) only returns chunks from the specified partiton . ` table_names ` specifies which tables to include
pub fn filtered_chunks<F, C>(
        &self,
        partition_key: Option<&str>,
        table_names: TableNameFilter<'_>,
        map: F,
    ) -> Vec<C>
    where
        F: Fn(&Chunk) -> C + Copy,
    {
        let mut chunks = Vec::new();
        let partitions = self.partitions.read();
        let partitions = match partition_key {
            None => itertools::Either::Left(partitions.values()),
            Some(partition_key) => {
                itertools::Either::Right(partitions.get(partition_key).into_iter())
            }
        };
        for partition in partitions {
            let partition = partition.read();
            chunks.extend(partition.filtered_chunks(table_names).map(|chunk| {
                let chunk = chunk.read();
                map(&chunk)
            }))
        }
        chunks
    }
pub fn filtered_chunks < F , C > ( & self , partition_key : Option < & str > , table_names : TableNameFilter < ' _ > , map : F , ) -> Vec < C > where F : Fn ( & Chunk ) -> C + Copy , { let mut chunks = Vec :: new ( ) ; let partitions = self . partitions . read ( ) ; let partitions = match partition_key { None => itertools :: Either :: Left ( partitions . values ( ) ) , Some ( partition_key ) => { itertools :: Either :: Right ( partitions . get ( partition_key ) . into_iter ( ) ) } } ; for partition in partitions { let partition = partition . read ( ) ; chunks . extend ( partition . filtered_chunks ( table_names ) . map ( | chunk | { let chunk = chunk . read ( ) ; map ( & chunk ) } ) ) } chunks }
Calls `map` with every chunk and returns a collection of the results
If `partition_key` is Some(partition_key) only returns chunks
from the specified partiton.
Calls ` map ` with every chunk and returns a collection of the results If ` partition_key ` is Some ( partition_key ) only returns chunks from the specified partiton .
&self
partition_key
Option<&str>
table_names
TableNameFilter<'_>
map
F
&self
partition_key
Option<&str>
table_names
TableNameFilter<'_>
map
F