pub struct ResourceName<'a>(/* private fields */);Expand description
A unique name/identifier of a resource.
Implementations§
Source§impl<'a> ResourceName<'a>
impl<'a> ResourceName<'a>
Sourcepub fn to_owned(&self) -> ResourceName<'static>
pub fn to_owned(&self) -> ResourceName<'static>
Convert a borrowed name to an un-borrwed name.
Source§impl<'a> ResourceName<'a>
impl<'a> ResourceName<'a>
Sourcepub fn named<I: Into<Identifier<'a>>>(name: I) -> Self
pub fn named<I: Into<Identifier<'a>>>(name: I) -> Self
Creates a ResourceName with name.
Sourcepub fn and<I: Into<Identifier<'a>>>(self, name: I) -> Self
pub fn and<I: Into<Identifier<'a>>>(self, name: I) -> Self
Adds another name segment.
Trait Implementations§
Source§impl<'a> AsRef<[Identifier<'a>]> for ResourceName<'a>
impl<'a> AsRef<[Identifier<'a>]> for ResourceName<'a>
Source§fn as_ref(&self) -> &[Identifier<'a>]
fn as_ref(&self) -> &[Identifier<'a>]
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl<'a> Clone for ResourceName<'a>
impl<'a> Clone for ResourceName<'a>
Source§fn clone(&self) -> ResourceName<'a>
fn clone(&self) -> ResourceName<'a>
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<'a> Debug for ResourceName<'a>
impl<'a> Debug for ResourceName<'a>
Source§impl<'a> Default for ResourceName<'a>
impl<'a> Default for ResourceName<'a>
Source§fn default() -> ResourceName<'a>
fn default() -> ResourceName<'a>
Returns the “default value” for a type. Read more
Source§impl<'de, 'a> Deserialize<'de> for ResourceName<'a>
impl<'de, 'a> Deserialize<'de> for ResourceName<'a>
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<'a> Display for ResourceName<'a>
impl<'a> Display for ResourceName<'a>
Source§impl<'b, 'a> From<&'b [Identifier<'a>]> for ResourceName<'a>
impl<'b, 'a> From<&'b [Identifier<'a>]> for ResourceName<'a>
Source§fn from(parts: &'b [Identifier<'a>]) -> Self
fn from(parts: &'b [Identifier<'a>]) -> Self
Converts to this type from the input type.
Source§impl<'a> From<&'a str> for ResourceName<'a>
impl<'a> From<&'a str> for ResourceName<'a>
Source§impl<'a> From<u64> for ResourceName<'a>
impl<'a> From<u64> for ResourceName<'a>
Source§impl<'a> IntoIterator for ResourceName<'a>
impl<'a> IntoIterator for ResourceName<'a>
Auto Trait Implementations§
impl<'a> Freeze for ResourceName<'a>
impl<'a> RefUnwindSafe for ResourceName<'a>
impl<'a> Send for ResourceName<'a>
impl<'a> Sync for ResourceName<'a>
impl<'a> Unpin for ResourceName<'a>
impl<'a> UnwindSafe for ResourceName<'a>
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