pub enum DatabaseLink {
DatabaseUrl(DatabaseUrl),
String(String),
Url(Url),
}Expand description
The DatabaseLink implementation enumerates the various compatible representations of a
connection or link to a database instance.
Variants§
Implementations§
Source§impl DatabaseLink
impl DatabaseLink
pub fn from_str<S>(s: S) -> Selfwhere
S: ToString,
pub const fn from_db_url(url: DatabaseUrl) -> Self
Sourcepub fn as_db_url(&self) -> DatabaseUrl
pub fn as_db_url(&self) -> DatabaseUrl
convert the instance into a DatabaseUrl
Trait Implementations§
Source§impl Clone for DatabaseLink
impl Clone for DatabaseLink
Source§fn clone(&self) -> DatabaseLink
fn clone(&self) -> DatabaseLink
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DatabaseLink
impl Debug for DatabaseLink
Source§impl Default for DatabaseLink
impl Default for DatabaseLink
Source§impl<'de> Deserialize<'de> for DatabaseLink
impl<'de> Deserialize<'de> for DatabaseLink
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<DatabaseLink> for DatabaseUrl
impl From<DatabaseLink> for DatabaseUrl
Source§fn from(link: DatabaseLink) -> Self
fn from(link: DatabaseLink) -> Self
Converts to this type from the input type.
Source§impl From<DatabaseLink> for Value
impl From<DatabaseLink> for Value
Source§fn from(link: DatabaseLink) -> Self
fn from(link: DatabaseLink) -> Self
Converts to this type from the input type.
Source§impl From<DatabaseUrl> for DatabaseLink
impl From<DatabaseUrl> for DatabaseLink
Source§fn from(url: DatabaseUrl) -> Self
fn from(url: DatabaseUrl) -> Self
Converts to this type from the input type.
Source§impl From<Url> for DatabaseLink
impl From<Url> for DatabaseLink
Source§impl Hash for DatabaseLink
impl Hash for DatabaseLink
Source§impl Ord for DatabaseLink
impl Ord for DatabaseLink
Source§fn cmp(&self, other: &DatabaseLink) -> Ordering
fn cmp(&self, other: &DatabaseLink) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for DatabaseLink
impl PartialEq for DatabaseLink
Source§impl PartialOrd for DatabaseLink
impl PartialOrd for DatabaseLink
Source§impl Serialize for DatabaseLink
impl Serialize for DatabaseLink
impl Eq for DatabaseLink
impl StructuralPartialEq for DatabaseLink
Auto Trait Implementations§
impl Freeze for DatabaseLink
impl RefUnwindSafe for DatabaseLink
impl Send for DatabaseLink
impl Sync for DatabaseLink
impl Unpin for DatabaseLink
impl UnwindSafe for DatabaseLink
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