Struct raw_string::RawString

source ·
pub struct RawString { /* private fields */ }
Expand description

A String with unchecked contents.

It is basically a Vec<u8>, to be interpreted as string. Unlike String, there are no guarantees about the contents being valid UTF-8. Unlike Vec<u8>, its Display and Debug implementations show a string, not an array of numbers.

Implementations§

source§

impl RawString

source

pub fn new() -> Self

source

pub fn with_capacity(capacity: usize) -> Self

source

pub fn from_bytes(bytes: Vec<u8>) -> Self

source

pub fn from_string(bytes: String) -> Self

source

pub fn into_bytes(self) -> Vec<u8>

source

pub fn capacity(&self) -> usize

source

pub fn reserve(&mut self, additional: usize)

source

pub fn reserve_exact(&mut self, additional: usize)

source

pub fn shrink_to_fit(&mut self)

source

pub fn clear(&mut self)

source

pub fn truncate(&mut self, new_len: usize)

source

pub fn pop(&mut self) -> Option<u8>

source

pub fn remove(&mut self, idx: usize) -> u8

source

pub fn retain<F: FnMut(u8) -> bool>(&mut self, f: F)

source

pub fn insert(&mut self, idx: usize, b: u8)

source

pub fn insert_str<T: AsRef<RawStr>>(&mut self, idx: usize, s: T)

source

pub fn split_off(&mut self, at: usize) -> RawString

source

pub fn drain<R: RangeBounds<usize>>(&mut self, range: R) -> Drain<'_, u8>

source

pub fn replace_range<R: RangeBounds<usize>, T: AsRef<RawStr>>( &mut self, range: R, replace_with: T )

source

pub fn into_boxed_raw_str(self) -> Box<RawStr>

source

pub fn push(&mut self, b: u8)

source

pub fn push_str<T: AsRef<RawStr>>(&mut self, s: T)

source

pub fn as_mut_bytes(&mut self) -> &mut Vec<u8>

source

pub fn to_string(self) -> Result<String, FromUtf8Error>

source

pub fn to_osstring(self) -> Result<OsString, FromUtf8Error>

Convert to an OsString.

On Unix, it never fails. On other platforms, it must be encoded as UTF-8.

A never-failing version for Unix only is available as unix::RawStringExt::into_osstring.

source

pub fn to_pathbuf(self) -> Result<PathBuf, FromUtf8Error>

Convert to a PathBuf.

On Unix, it never fails. On other platforms, it must be encoded as UTF-8.

A never-failing version for Unix only is available as unix::RawStringExt::into_pathbuf.

Methods from Deref<Target = RawStr>§

source

pub fn as_bytes(&self) -> &[u8]

source

pub fn as_bytes_mut(&mut self) -> &mut [u8]

source

pub fn len(&self) -> usize

source

pub fn is_empty(&self) -> bool

source

pub fn as_ptr(&self) -> *const u8

source

pub fn first(&self) -> Option<u8>

source

pub fn first_mut(&mut self) -> Option<&mut u8>

source

pub fn last(&self) -> Option<u8>

source

pub fn last_mut(&mut self) -> Option<&mut u8>

source

pub fn split_first(&self) -> Option<(u8, &RawStr)>

source

pub fn split_first_mut(&mut self) -> Option<(&mut u8, &mut RawStr)>

source

pub fn split_last(&self) -> Option<(u8, &RawStr)>

source

pub fn split_last_mut(&mut self) -> Option<(&mut u8, &mut RawStr)>

source

pub fn split_at(&self, mid: usize) -> (&RawStr, &RawStr)

source

pub fn split_at_mut(&mut self, mid: usize) -> (&mut RawStr, &mut RawStr)

source

pub fn contains_byte(&self, x: u8) -> bool

source

pub fn starts_with<T: AsRef<RawStr>>(&self, x: T) -> bool

source

pub fn ends_with<T: AsRef<RawStr>>(&self, x: T) -> bool

source

pub fn get<I: RawStrIndex>(&self, index: I) -> Option<&I::Output>

source

pub fn get_mut<I: RawStrIndex>(&mut self, index: I) -> Option<&mut I::Output>

source

pub unsafe fn get_unchecked<I: RawStrIndex>(&self, index: I) -> &I::Output

source

pub unsafe fn get_unchecked_mut<I: RawStrIndex>( &mut self, index: I ) -> &mut I::Output

source

pub unsafe fn slice_unchecked(&self, begin: usize, end: usize) -> &RawStr

source

pub unsafe fn slice_mut_unchecked( &mut self, begin: usize, end: usize ) -> &mut RawStr

source

pub fn bytes(&self) -> Cloned<Iter<'_, u8>>

source

pub fn bytes_mut(&mut self) -> IterMut<'_, u8>

source

pub fn utf8_chunks(&self) -> Utf8ChunksIter<'_>

Iterate over chunks of valid UTF-8.

The iterator iterates over the chunks of valid UTF-8 separated by any broken characters, which could be replaced by the unicode replacement character.

source

pub fn to_str(&self) -> Result<&str, Utf8Error>

source

pub fn to_osstr(&self) -> Result<&OsStr, Utf8Error>

Convert to an OsStr.

On Unix, it never fails. On other platforms, it must be encoded as UTF-8.

A never-failing version for Unix only is available as unix::RawStrExt::as_osstr.

source

pub fn to_path(&self) -> Result<&Path, Utf8Error>

Convert to a Path.

On Unix, it never fails. On other platforms, it must be encoded as UTF-8.

A never-failing version for Unix only is available as unix::RawStrExt::as_path.

source

pub fn is_ascii(&self) -> bool

source

pub fn eq_ignore_ascii_case(&self, other: &RawStr) -> bool

source

pub fn make_ascii_uppercase(&mut self)

source

pub fn make_ascii_lowercase(&mut self)

Trait Implementations§

source§

impl AsRef<[u8]> for RawString

source§

fn as_ref(&self) -> &[u8]

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawStr> for RawString

source§

fn as_ref(&self) -> &RawStr

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Borrow<RawStr> for RawString

source§

fn borrow(&self) -> &RawStr

Immutably borrows from an owned value. Read more
source§

impl Clone for RawString

source§

fn clone(&self) -> RawString

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RawString

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for RawString

source§

fn default() -> RawString

Returns the “default value” for a type. Read more
source§

impl Deref for RawString

§

type Target = RawStr

The resulting type after dereferencing.
source§

fn deref(&self) -> &RawStr

Dereferences the value.
source§

impl DerefMut for RawString

source§

fn deref_mut(&mut self) -> &mut RawStr

Mutably dereferences the value.
source§

impl Display for RawString

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'a> From<&'a [u8]> for RawString

source§

fn from(src: &'a [u8]) -> RawString

Converts to this type from the input type.
source§

impl<'a> From<&'a RawStr> for RawString

source§

fn from(src: &'a RawStr) -> RawString

Converts to this type from the input type.
source§

impl<'a> From<&'a str> for RawString

source§

fn from(src: &'a str) -> RawString

Converts to this type from the input type.
source§

impl From<String> for RawString

source§

fn from(src: String) -> RawString

Converts to this type from the input type.
source§

impl From<Vec<u8, Global>> for RawString

source§

fn from(src: Vec<u8>) -> RawString

Converts to this type from the input type.
source§

impl Hash for RawString

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl<'a> IntoIterator for &'a RawString

§

type Item = u8

The type of the elements being iterated over.
§

type IntoIter = Cloned<Iter<'a, u8>>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
source§

impl<'a> IntoIterator for &'a mut RawString

§

type Item = &'a mut u8

The type of the elements being iterated over.
§

type IntoIter = IterMut<'a, u8>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
source§

impl IntoIterator for RawString

§

type Item = u8

The type of the elements being iterated over.
§

type IntoIter = IntoIter<u8, Global>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
source§

impl Ord for RawString

source§

fn cmp(&self, other: &RawString) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Selfwhere Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Selfwhere Self: Sized + PartialOrd<Self>,

Restrict a value to a certain interval. Read more
source§

impl PartialEq<&[u8]> for RawString

source§

fn eq(&self, other: &&[u8]) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<&RawStr> for RawString

source§

fn eq(&self, other: &&RawStr) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<&str> for RawString

source§

fn eq(&self, other: &&str) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<[u8]> for RawString

source§

fn eq(&self, other: &[u8]) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawStr> for RawString

source§

fn eq(&self, other: &RawStr) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for &[u8]

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for &RawStr

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for &str

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for [u8]

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for RawStr

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for RawString

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<RawString> for str

source§

fn eq(&self, other: &RawString) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialEq<str> for RawString

source§

fn eq(&self, other: &str) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd<&[u8]> for RawString

source§

fn partial_cmp(&self, other: &&[u8]) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<&RawStr> for RawString

source§

fn partial_cmp(&self, other: &&RawStr) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<&str> for RawString

source§

fn partial_cmp(&self, other: &&str) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<[u8]> for RawString

source§

fn partial_cmp(&self, other: &[u8]) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawStr> for RawString

source§

fn partial_cmp(&self, other: &RawStr) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for &[u8]

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for &RawStr

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for &str

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for [u8]

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for RawStr

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for RawString

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<RawString> for str

source§

fn partial_cmp(&self, other: &RawString) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl PartialOrd<str> for RawString

source§

fn partial_cmp(&self, other: &str) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl RawStringExt for RawString

Conversions only available on unix.

source§

impl Eq for RawString

source§

impl StructuralEq for RawString

source§

impl StructuralPartialEq for RawString

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToString for Twhere T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.