pub struct ModelConnectionsBuilder { /* private fields */ }Expand description
Incrementally builds a ModelConnections value.
§Panics
build panics if no primary connection has been set.
Implementations§
Source§impl ModelConnectionsBuilder
impl ModelConnectionsBuilder
Sourcepub fn primary(self, connection: ModelConnection) -> Self
pub fn primary(self, connection: ModelConnection) -> Self
Set the primary model connection.
Sourcepub fn fallback(self, connection: ModelConnection) -> Self
pub fn fallback(self, connection: ModelConnection) -> Self
Add a fallback model connection.
Sourcepub fn build(self) -> ModelConnections
pub fn build(self) -> ModelConnections
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ModelConnectionsBuilder
impl !RefUnwindSafe for ModelConnectionsBuilder
impl Send for ModelConnectionsBuilder
impl Sync for ModelConnectionsBuilder
impl Unpin for ModelConnectionsBuilder
impl UnsafeUnpin for ModelConnectionsBuilder
impl !UnwindSafe for ModelConnectionsBuilder
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