Struct msi::Column
[−]
[src]
pub struct Column { /* fields omitted */ }
A database column.
Methods
impl Column
[src]
fn build(name: &str) -> ColumnBuilder
Begins building a new column with the given name.
Examples
let column = msi::Column::build("Foo").nullable().int16(); assert_eq!(column.name(), "Foo"); assert!(column.is_nullable()); assert_eq!(column.coltype(), msi::ColumnType::Int16);
fn name(&self) -> &str
Returns the name of the column.
fn coltype(&self) -> ColumnType
Returns the type of data stored in the column.
fn is_localizable(&self) -> bool
Returns true if values in this column can be localized.
fn is_nullable(&self) -> bool
Returns true if values in this column can be null.
fn is_primary_key(&self) -> bool
Returns true if this is primary key column.
fn value_range(&self) -> Option<(i32, i32)>
Returns the (min, max) integer value range for this column, if any.
fn category(&self) -> Option<ColumnCategory>
Returns the string value category for this column, if any.
fn enum_values(&self) -> Option<&[String]>
Returns the list of valid enum values for this column, if any.
fn is_valid_value(&self, value: &Value) -> bool
Returns true if the given value is valid for this column.
Trait Implementations
impl Clone for Column
[src]
fn clone(&self) -> Column
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more