pub struct Column {
pub name: String,
pub column_type: ValueType,
pub limiter: ValueLimiter,
}Expand description
Column of virtual data
Column is “text” type by default but can be further configured with value limiter.
Fields
name: Stringcolumn_type: ValueTypelimiter: ValueLimiterImplementations
sourceimpl Column
impl Column
pub fn new(
name: &str,
column_type: ValueType,
limiter: Option<ValueLimiter>
) -> Self
sourcepub fn get_column_type(&self) -> &ValueType
pub fn get_column_type(&self) -> &ValueType
Get column type
sourcepub fn set_limiter(&mut self, limiter: ValueLimiter)
pub fn set_limiter(&mut self, limiter: ValueLimiter)
Apply limiter to a column
sourcepub fn get_default_value(&self) -> Value
pub fn get_default_value(&self) -> Value
Get default value by column
Every value type has it’s own default value. The default value can differ by limiter’s variant of patterns and should comply to a limter’s predicate.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Column
impl Send for Column
impl Sync for Column
impl Unpin for Column
impl UnwindSafe for Column
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more