[][src]Struct pstr::MowStr

pub struct MowStr(_);

Mutable on Write Interning Pool String

Implementations

impl MowStr[src]

pub fn new(s: impl AsRef<str>) -> Self[src]

pub fn new_mut(s: impl Into<String>) -> Self[src]

pub fn mut_empty() -> Self[src]

pub fn mut_with_capacity(capacity: usize) -> Self[src]

pub fn from_utf8(s: impl AsRef<[u8]>) -> Result<Self, Utf8Error>[src]

pub fn from_utf16(s: impl AsRef<[u16]>) -> Result<Self, FromUtf16Error>[src]

pub fn from_string(s: String) -> Self[src]

pub fn from_string_mut(s: String) -> Self[src]

pub fn from_boxed_str(s: Box<str>) -> Self[src]

pub fn from_boxed_str_mut(s: Box<str>) -> Self[src]

pub fn from_istr(s: IStr) -> Self[src]

pub fn from_istr_mut(s: IStr) -> Self[src]

pub unsafe fn from_utf8_unchecked(bytes: impl AsRef<[u8]>) -> Self[src]

impl MowStr[src]

pub fn intern(&mut self)[src]

pub fn to_mut(&mut self)[src]

pub fn mutdown(&mut self) -> &mut String[src]

pub fn is_interned(&self) -> bool[src]

pub fn is_mutable(&self) -> bool[src]

impl MowStr[src]

pub fn ref_str(&self) -> &str[src]

pub fn mut_str(&mut self) -> &mut str[src]

pub fn mut_string(&mut self) -> &mut String[src]

pub fn as_str(&self) -> &str[src]

pub fn as_mut_str(&mut self) -> &mut str[src]

pub fn as_mut_string(&mut self) -> &mut String[src]

pub unsafe fn as_mut_vec(&mut self) -> &mut Vec<u8>[src]

pub fn into_string(self) -> String[src]

pub fn into_boxed_str(self) -> Box<str>[src]

impl MowStr[src]

pub fn push_str(&mut self, string: impl AsRef<str>)[src]

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

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

pub fn shrink_to_fit(&mut self)[src]

pub fn push(&mut self, ch: char)[src]

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

pub fn pop(&mut self) -> Option<char>[src]

pub fn remove(&mut self, idx: usize) -> char[src]

pub fn retain<F: FnMut(char) -> bool>(&mut self, f: F)[src]

pub fn insert(&mut self, idx: usize, ch: char)[src]

pub fn insert_str(&mut self, idx: usize, string: &str)[src]

pub fn split_off(&mut self, at: usize) -> MowStr[src]

pub fn clear(&mut self)[src]

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

pub fn replace_range<R: RangeBounds<usize>>(
    &mut self,
    range: R,
    replace_with: &str
)
[src]

Trait Implementations

impl<'_> Add<&'_ str> for MowStr[src]

type Output = MowStr

The resulting type after applying the + operator.

impl<'_> AddAssign<&'_ str> for MowStr[src]

impl AsMut<String> for MowStr[src]

impl AsMut<str> for MowStr[src]

impl AsRef<[u8]> for MowStr[src]

impl AsRef<OsStr> for MowStr[src]

impl AsRef<Path> for MowStr[src]

impl AsRef<str> for MowStr[src]

impl Borrow<str> for MowStr[src]

impl BorrowMut<str> for MowStr[src]

impl Clone for MowStr[src]

impl Debug for MowStr[src]

impl Deref for MowStr[src]

type Target = str

The resulting type after dereferencing.

impl DerefMut for MowStr[src]

impl Eq for MowStr[src]

impl<'a> Extend<&'a char> for MowStr[src]

impl<'a> Extend<&'a str> for MowStr[src]

impl Extend<Box<str>> for MowStr[src]

impl<'a> Extend<Cow<'a, str>> for MowStr[src]

impl Extend<IStr> for MowStr[src]

impl Extend<MowStr> for MowStr[src]

impl Extend<String> for MowStr[src]

impl<'_> From<&'_ String> for MowStr[src]

impl<'_> From<&'_ mut str> for MowStr[src]

impl<'_> From<&'_ str> for MowStr[src]

impl<'a> From<&'a MowStr> for Cow<'a, str>[src]

impl From<Box<str>> for MowStr[src]

impl<'a> From<Cow<'a, str>> for MowStr[src]

impl From<IStr> for MowStr[src]

impl From<MowStr> for String[src]

impl From<MowStr> for Box<str>[src]

impl From<MowStr> for IStr[src]

impl From<MowStr> for Vec<u8>[src]

impl From<MowStr> for Arc<str>[src]

impl From<MowStr> for Rc<str>[src]

impl<'a> From<MowStr> for Cow<'a, str>[src]

impl From<MowStr> for Box<dyn Error>[src]

impl From<MowStr> for Box<dyn Error + Send + Sync>[src]

impl From<MowStr> for OsString[src]

impl From<MowStr> for PathBuf[src]

impl From<String> for MowStr[src]

impl From<char> for MowStr[src]

impl<'a> FromIterator<&'a char> for MowStr[src]

impl<'a> FromIterator<&'a str> for MowStr[src]

impl FromIterator<Box<str>> for MowStr[src]

impl<'a> FromIterator<Cow<'a, str>> for MowStr[src]

impl FromIterator<String> for MowStr[src]

impl FromIterator<char> for MowStr[src]

impl FromStr for MowStr[src]

type Err = ParseError

The associated error which can be returned from parsing.

impl Hash for MowStr[src]

impl<I: SliceIndex<str>> Index<I> for MowStr[src]

type Output = <I as SliceIndex<str>>::Output

The returned type after indexing.

impl<I: SliceIndex<str>> IndexMut<I> for MowStr[src]

impl Interned for MowStr[src]

impl Interning for MowStr[src]

type Outern = MowStr

impl Muterned for MowStr[src]

impl Muterning for MowStr[src]

type Outern = MowStr

impl Ord for MowStr[src]

impl PartialEq<MowStr> for MowStr[src]

impl PartialOrd<MowStr> for MowStr[src]

impl StructuralEq for MowStr[src]

impl StructuralPartialEq for MowStr[src]

impl ToSocketAddrs for MowStr[src]

type Iter = <str as ToSocketAddrs>::Iter

Returned iterator over socket addresses which this type may correspond to. Read more

impl ToString for MowStr[src]

impl Write for MowStr[src]

Auto Trait Implementations

impl RefUnwindSafe for MowStr

impl Send for MowStr

impl Sync for MowStr

impl Unpin for MowStr

impl UnwindSafe for MowStr

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.