Struct semilattice_database::Database
source · pub struct Database { /* private fields */ }Implementations§
source§impl Database
impl Database
pub fn collections(&self) -> Vec<String>
pub fn collection(&self, id: i32) -> Option<&Collection>
pub fn collection_mut(&mut self, id: i32) -> Option<&mut Collection>
pub fn collection_id(&self, name: &str) -> Option<i32>
pub fn collection_id_or_create(&mut self, name: &str) -> i32
pub fn delete_collection(&mut self, name: &str)
source§impl Database
impl Database
pub fn relation(&self) -> Arc<RwLock<RelationIndex>>
pub fn register_relation( &mut self, key_name: &str, depend: &CollectionRow, pend: CollectionRow )
pub fn register_relations( &mut self, depend: &CollectionRow, pends: Vec<(String, CollectionRow)> )
pub fn depends( &self, key: Option<&str>, pend_collection_id: i32, pend_row: u32 ) -> Vec<Depend>
source§impl Database
impl Database
pub fn new( dir: PathBuf, collection_settings: Option<HashMap<String, DataOption>> ) -> Self
pub fn delete_recursive(&mut self, target: &CollectionRow)
Auto Trait Implementations§
impl RefUnwindSafe for Database
impl Send for Database
impl Sync for Database
impl Unpin for Database
impl UnwindSafe for Database
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