pub struct DatabaseCapability(/* private fields */);Implementations§
Source§impl DatabaseCapability
impl DatabaseCapability
Sourcepub fn new(input: impl AsRef<str>) -> Result<DatabaseCapability, DatabaseError>
pub fn new(input: impl AsRef<str>) -> Result<DatabaseCapability, 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 DatabaseCapability
impl AsRef<str> for DatabaseCapability
Source§impl Clone for DatabaseCapability
impl Clone for DatabaseCapability
Source§fn clone(&self) -> DatabaseCapability
fn clone(&self) -> DatabaseCapability
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 DatabaseCapability
impl Debug for DatabaseCapability
Source§impl Display for DatabaseCapability
impl Display for DatabaseCapability
Source§impl FromStr for DatabaseCapability
impl FromStr for DatabaseCapability
Source§type Err = DatabaseError
type Err = DatabaseError
The associated error which can be returned from parsing.
Source§fn from_str(
input: &str,
) -> Result<DatabaseCapability, <DatabaseCapability as FromStr>::Err>
fn from_str( input: &str, ) -> Result<DatabaseCapability, <DatabaseCapability as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for DatabaseCapability
impl Hash for DatabaseCapability
Source§impl Ord for DatabaseCapability
impl Ord for DatabaseCapability
Source§fn cmp(&self, other: &DatabaseCapability) -> Ordering
fn cmp(&self, other: &DatabaseCapability) -> 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 DatabaseCapability
impl PartialEq for DatabaseCapability
Source§fn eq(&self, other: &DatabaseCapability) -> bool
fn eq(&self, other: &DatabaseCapability) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for DatabaseCapability
impl PartialOrd for DatabaseCapability
Source§impl TryFrom<&str> for DatabaseCapability
impl TryFrom<&str> for DatabaseCapability
Source§type Error = DatabaseError
type Error = DatabaseError
The type returned in the event of a conversion error.
Source§fn try_from(
value: &str,
) -> Result<DatabaseCapability, <DatabaseCapability as TryFrom<&str>>::Error>
fn try_from( value: &str, ) -> Result<DatabaseCapability, <DatabaseCapability as TryFrom<&str>>::Error>
Performs the conversion.
impl Eq for DatabaseCapability
impl StructuralPartialEq for DatabaseCapability
Auto Trait Implementations§
impl Freeze for DatabaseCapability
impl RefUnwindSafe for DatabaseCapability
impl Send for DatabaseCapability
impl Sync for DatabaseCapability
impl Unpin for DatabaseCapability
impl UnsafeUnpin for DatabaseCapability
impl UnwindSafe for DatabaseCapability
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