[−][src]Struct langtag::PrivateUseTag
Private use tag.
Implementations
impl<T: AsRef<[u8]>> PrivateUseTag<T>
[src]
pub fn new(t: T) -> Result<PrivateUseTag<T>, T>
[src]
Parse and use the given data as a private use tag.
impl PrivateUseTag
[src]
pub fn parse<'a, T: AsRef<[u8]> + ?Sized>(
bytes: &T
) -> Result<&'a PrivateUseTag, Error>
[src]
bytes: &T
) -> Result<&'a PrivateUseTag, Error>
Parse and borrow the given data as a private use tag.
impl<T: AsRef<[u8]> + ?Sized> PrivateUseTag<T>
[src]
pub fn as_bytes(&self) -> &[u8]
[src]
Returns the bytes representation of this private use tag.
pub fn as_str(&self) -> &str
[src]
Returns the string representation of this private use tag.
pub fn subtags(&self) -> &PrivateUseSubtags
[src]
Iterate through the subtags.
impl<T: AsMut<Vec<u8>>> PrivateUseTag<T>
[src]
pub fn subtags_mut(&mut self) -> PrivateUseSubtagsMut<'_>
[src]
Modify the subtags.
Trait Implementations
impl<T: AsRef<[u8]> + ?Sized> AsRef<[u8]> for PrivateUseTag<T>
[src]
impl<T: AsRef<[u8]> + ?Sized> Debug for PrivateUseTag<T>
[src]
impl<T: AsRef<[u8]> + ?Sized> Display for PrivateUseTag<T>
[src]
impl<T: AsRef<[u8]> + ?Sized> Eq for PrivateUseTag<T>
[src]
impl<T: AsRef<[u8]> + ?Sized> Hash for PrivateUseTag<T>
[src]
pub fn hash<H: Hasher>(&self, h: &mut H)
[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl<T: AsRef<[u8]> + ?Sized, U: AsRef<[u8]> + ?Sized> PartialEq<U> for PrivateUseTag<T>
[src]
Auto Trait Implementations
impl<T: ?Sized> RefUnwindSafe for PrivateUseTag<T> where
T: RefUnwindSafe,
[src]
T: RefUnwindSafe,
impl<T: ?Sized> Send for PrivateUseTag<T> where
T: Send,
[src]
T: Send,
impl<T: ?Sized> Sync for PrivateUseTag<T> where
T: Sync,
[src]
T: Sync,
impl<T: ?Sized> Unpin for PrivateUseTag<T> where
T: Unpin,
[src]
T: Unpin,
impl<T: ?Sized> UnwindSafe for PrivateUseTag<T> where
T: UnwindSafe,
[src]
T: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,