pub struct DatabaseVersion(/* private fields */);Implementations§
Source§impl DatabaseVersion
impl DatabaseVersion
Sourcepub fn new(input: impl AsRef<str>) -> Result<DatabaseVersion, DatabaseError>
pub fn new(input: impl AsRef<str>) -> Result<DatabaseVersion, DatabaseError>
Creates a database label from non-empty text.
§Errors
Returns DatabaseError when the label is empty or contains control characters.
Sourcepub fn into_string(self) -> String
pub fn into_string(self) -> String
Consumes the label and returns the owned string.
Trait Implementations§
Source§impl AsRef<str> for DatabaseVersion
impl AsRef<str> for DatabaseVersion
Source§impl Clone for DatabaseVersion
impl Clone for DatabaseVersion
Source§fn clone(&self) -> DatabaseVersion
fn clone(&self) -> DatabaseVersion
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 DatabaseVersion
impl Debug for DatabaseVersion
Source§impl Display for DatabaseVersion
impl Display for DatabaseVersion
Source§impl FromStr for DatabaseVersion
impl FromStr for DatabaseVersion
Source§type Err = DatabaseError
type Err = DatabaseError
The associated error which can be returned from parsing.
Source§fn from_str(
input: &str,
) -> Result<DatabaseVersion, <DatabaseVersion as FromStr>::Err>
fn from_str( input: &str, ) -> Result<DatabaseVersion, <DatabaseVersion as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for DatabaseVersion
impl Hash for DatabaseVersion
Source§impl Ord for DatabaseVersion
impl Ord for DatabaseVersion
Source§fn cmp(&self, other: &DatabaseVersion) -> Ordering
fn cmp(&self, other: &DatabaseVersion) -> Ordering
1.21.0 (const: unstable) · 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 DatabaseVersion
impl PartialEq for DatabaseVersion
Source§fn eq(&self, other: &DatabaseVersion) -> bool
fn eq(&self, other: &DatabaseVersion) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for DatabaseVersion
impl PartialOrd for DatabaseVersion
Source§impl TryFrom<&str> for DatabaseVersion
impl TryFrom<&str> for DatabaseVersion
Source§type Error = DatabaseError
type Error = DatabaseError
The type returned in the event of a conversion error.
Source§fn try_from(
value: &str,
) -> Result<DatabaseVersion, <DatabaseVersion as TryFrom<&str>>::Error>
fn try_from( value: &str, ) -> Result<DatabaseVersion, <DatabaseVersion as TryFrom<&str>>::Error>
Performs the conversion.
impl Eq for DatabaseVersion
impl StructuralPartialEq for DatabaseVersion
Auto Trait Implementations§
impl Freeze for DatabaseVersion
impl RefUnwindSafe for DatabaseVersion
impl Send for DatabaseVersion
impl Sync for DatabaseVersion
impl Unpin for DatabaseVersion
impl UnsafeUnpin for DatabaseVersion
impl UnwindSafe for DatabaseVersion
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