pub struct Schema { /* private fields */ }
Expand description
A namespace in a database.
The schema only holds a reference to the actual tables, which are owned by the VM.
Implementationsยง
Sourceยงimpl Schema
impl Schema
pub fn new(name: BoundedString) -> Self
Sourcepub fn name(&self) -> &BoundedString
pub fn name(&self) -> &BoundedString
The name of the schema.
Sourcepub fn tables(&self) -> &Vec<TableIndex>
pub fn tables(&self) -> &Vec<TableIndex>
All the tables in the schema.
Sourcepub fn add_table(&mut self, table: TableIndex) -> &mut Self
pub fn add_table(&mut self, table: TableIndex) -> &mut Self
Add a new table to the schema.
Trait Implementationsยง
Auto Trait Implementationsยง
impl Freeze for Schema
impl RefUnwindSafe for Schema
impl Send for Schema
impl Sync for Schema
impl Unpin for Schema
impl UnwindSafe for Schema
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