pub struct TableConfig {
pub path: TablePath,
pub fields: UniqueList<ColumnConfig>,
}Fields§
§path: TablePath§fields: UniqueList<ColumnConfig>Implementations§
Source§impl TableConfig
impl TableConfig
pub fn new<R>(path: R) -> Result<Self, ConfigError>
pub fn add_column(self, field: ColumnConfig) -> Result<Self, ConfigError>
pub fn get_column( &self, name: impl Into<String>, ) -> Result<Option<&ColumnConfig>, ConfigError>
pub fn has_column(&self, name: impl Into<String>) -> Result<bool, ConfigError>
Sourcepub fn sort_indexes_by_type(&mut self)
pub fn sort_indexes_by_type(&mut self)
Sorts all indexes by type for each field. Indexes are sorted in place.
Trait Implementations§
Source§impl Clone for TableConfig
impl Clone for TableConfig
Source§fn clone(&self) -> TableConfig
fn clone(&self) -> TableConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TableConfig
impl Debug for TableConfig
Source§impl<'de> Deserialize<'de> for TableConfig
impl<'de> Deserialize<'de> for TableConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq<&str> for TableConfig
impl PartialEq<&str> for TableConfig
Source§impl PartialEq<TablePath> for TableConfig
impl PartialEq<TablePath> for TableConfig
Source§impl PartialEq for TableConfig
impl PartialEq for TableConfig
Source§impl Serialize for TableConfig
impl Serialize for TableConfig
impl ListEntry for TableConfig
Auto Trait Implementations§
impl Freeze for TableConfig
impl RefUnwindSafe for TableConfig
impl Send for TableConfig
impl Sync for TableConfig
impl Unpin for TableConfig
impl UnwindSafe for TableConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more