Skip to main content

Population

Struct Population 

Source
pub struct Population {
    pub driver: Table,
    pub keys: Vec<String>,
    pub data: Vec<(Table, HashMap<String, Vec<u32>>)>,
    pub orphan_rows: u64,
    pub orphan_keys: u64,
    pub orphan_samples: Vec<String>,
    /* private fields */
}
Expand description

The population of a per-row output.

Fields§

§driver: Table§keys: Vec<String>

Each driver row’s key, shown (a_b for a composite key), in driver order.

§data: Vec<(Table, HashMap<String, Vec<u32>>)>

Each data query, and its rows by key (index form).

§orphan_rows: u64

Rows of data queries whose key isn’t in the driver: how many, how many keys, and up to 10 of them.

§orphan_keys: u64§orphan_samples: Vec<String>

Implementations§

Source§

impl Population

Source

pub fn build( driver: Table, data: Vec<Table>, key: &[String], ) -> Result<Population, String>

Index the driver and each data query by key. A duplicate driver key is an error.

Source

pub fn len(&self) -> usize

Source

pub fn is_empty(&self) -> bool

Source

pub fn slices(&self, i: usize) -> Result<Vec<RecordBatch>, String>

Row i’s slice of each data query, in order.

Source

pub fn slice_len(&self, i: usize, q: usize) -> u64

How many rows of data query q row i has.

Source

pub fn driver_row(&self, i: usize) -> RecordBatch

Row i of the driver, as a one-row batch.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.