pub struct DatabaseRegistry { /* private fields */ }Expand description
Global database object registry for XDL object system integration Maps object IDs to database instances
Implementations§
Source§impl DatabaseRegistry
impl DatabaseRegistry
Sourcepub async fn register_database(&self, db: XDLDatabase) -> usize
pub async fn register_database(&self, db: XDLDatabase) -> usize
Register a new database object and return its ID
Sourcepub async fn get_database(&self, id: usize) -> Option<Arc<RwLock<XDLDatabase>>>
pub async fn get_database(&self, id: usize) -> Option<Arc<RwLock<XDLDatabase>>>
Get a database by ID
Sourcepub async fn unregister_database(&self, id: usize)
pub async fn unregister_database(&self, id: usize)
Remove a database from the registry
Sourcepub async fn register_recordset(&self, recordset: Recordset) -> usize
pub async fn register_recordset(&self, recordset: Recordset) -> usize
Register a recordset and return its ID
Sourcepub async fn get_recordset(&self, id: usize) -> Option<Arc<RwLock<Recordset>>>
pub async fn get_recordset(&self, id: usize) -> Option<Arc<RwLock<Recordset>>>
Get a recordset by ID
Sourcepub async fn unregister_recordset(&self, id: usize)
pub async fn unregister_recordset(&self, id: usize)
Remove a recordset from the registry
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for DatabaseRegistry
impl !RefUnwindSafe for DatabaseRegistry
impl Send for DatabaseRegistry
impl Sync for DatabaseRegistry
impl Unpin for DatabaseRegistry
impl !UnwindSafe for DatabaseRegistry
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more