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.