pub type WideUtfString = Utf32String;
Expand description
Alias for Utf16String
or Utf32String
depending on platform. Intended to match typical C
wchar_t
size on platform.
Aliased Type§
struct WideUtfString { /* private fields */ }
Implementations
Source§impl Utf32String
impl Utf32String
Sourcepub const fn new() -> Self
pub const fn new() -> Self
Creates a new empty string.
Given that the string is empty, this will not allocate any initial buffer. While
that means this initial operation is very inexpensive, it may cause excessive
allocations later when you add data. If you have an idea of how much data the
string will hold, consider with_capacity
instead to
prevent excessive re-allocation.
Sourcepub fn with_capacity(capacity: usize) -> Self
pub fn with_capacity(capacity: usize) -> Self
Creates a new empty string with a particular capacity.
This string has an internal buffer to hold its data. The capacity is the length of
that buffer, and can be queried with the capacity
method. This
method creates and empty string, but one with an initial buffer that can hold
capacity
elements. This is useful when you may be appending a bunch of data to
the string, reducing the number of reallocations it needs to do.
If the given capacity is 0
, no allocation will occur, and this method is identical
to the new
method.
Sourcepub unsafe fn from_vec_unchecked(v: impl Into<Vec<u32>>) -> Self
pub unsafe fn from_vec_unchecked(v: impl Into<Vec<u32>>) -> Self
Converts a u32
vector to a string without checking that the string contains valid
UTF-32.
See the safe version, from_vec
, for more information.
§Safety
This function is unsafe because it does not check that the vector passed to it is valid
UTF-32. If this constraint is violated, undefined behavior results as it is assumed the
Utf32String
is always valid UTF-32.
§Examples
use widestring::Utf32String;
let sparkle_heart = vec![0x1f496];
let sparkle_heart = unsafe { Utf32String::from_vec_unchecked(sparkle_heart) };
assert_eq!("💖", sparkle_heart);
Sourcepub fn from_str<S: AsRef<str> + ?Sized>(s: &S) -> Self
pub fn from_str<S: AsRef<str> + ?Sized>(s: &S) -> Self
Re-encodes a UTF-8–encoded string slice into a UTF-32–encoded string.
This operation is lossless and infallible, but requires a memory allocation.
§Examples
use widestring::Utf32String;
let music = Utf32String::from_str("𝄞music");
assert_eq!(utf32str!("𝄞music"), music);
Sourcepub fn as_mut_utfstr(&mut self) -> &mut Utf32Str
pub fn as_mut_utfstr(&mut self) -> &mut Utf32Str
Converts a string into a mutable string slice.
Sourcepub fn as_ustr(&self) -> &U32Str
pub fn as_ustr(&self) -> &U32Str
Converts this string into a wide string of undefined encoding.
Sourcepub fn into_vec(self) -> Vec<u32>
pub fn into_vec(self) -> Vec<u32>
Converts a string into a vector of its elements.
This consumes the string without copying its contents.
Sourcepub fn push_utfstr<S: AsRef<Utf32Str> + ?Sized>(&mut self, string: &S)
pub fn push_utfstr<S: AsRef<Utf32Str> + ?Sized>(&mut self, string: &S)
Appends a given string slice onto the end of this string.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("foo");
s.push_utfstr(utf32str!("bar"));
assert_eq!(utf32str!("foobar"), s);
Sourcepub fn reserve(&mut self, additional: usize)
pub fn reserve(&mut self, additional: usize)
Ensures that this string’s capacity is at least additional
elements larger than
its length.
The capacity may be increased by more than additional
elements if it chooses, to
prevent frequent reallocations.
If you do not want this “at least” behavior, see the
reserve_exact
method.
§Panics
Panics if the new capacity overflows usize
.
Sourcepub fn reserve_exact(&mut self, additional: usize)
pub fn reserve_exact(&mut self, additional: usize)
Sourcepub fn shrink_to_fit(&mut self)
pub fn shrink_to_fit(&mut self)
Shrinks the capacity of this string to match its length.
Sourcepub fn shrink_to(&mut self, min_capacity: usize)
pub fn shrink_to(&mut self, min_capacity: usize)
Shrinks the capacity of this string with a lower bound.
The capacity will remain at least as large as both the length and the supplied value.
If the current capacity is less than the lower limit, this is a no-op.
Sourcepub unsafe fn as_mut_vec(&mut self) -> &mut Vec<u32>
pub unsafe fn as_mut_vec(&mut self) -> &mut Vec<u32>
Returns a mutable reference to the contents of this string.
§Safety
This function is unsafe because it does not check that the values in the vector are valid UTF-16. If this constraint is violated, it may cause undefined beahvior with future users of the string, as it is assumed that this string is always valid UTF-16.
Sourcepub fn len(&self) -> usize
pub fn len(&self) -> usize
Returns the length of this string in number of elements, not char
s or
graphemes.
In other words, it might not be what a human considers the length of the string.
Sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Returns true
if this string has a length of zero, and false
otherwise.
Sourcepub fn clear(&mut self)
pub fn clear(&mut self)
Truncates the string, removing all contents.
While this means the string will have a length of zero, it does not touch its capacity.
Sourcepub fn into_boxed_utfstr(self) -> Box<Utf32Str>
pub fn into_boxed_utfstr(self) -> Box<Utf32Str>
Converts this string into a boxed string slice.
This will drop excess capacity.
Source§impl Utf32String
impl Utf32String
Sourcepub fn from_vec(v: impl Into<Vec<u32>>) -> Result<Self, Utf32Error>
pub fn from_vec(v: impl Into<Vec<u32>>) -> Result<Self, Utf32Error>
Converts a u32
vector of UTF-32 data to a string.
Not all slices of u32
values are valid to convert, since Utf32String
requires that
it is always valid UTF-32. This function checks to ensure that the values are valid UTF-32,
and then does the conversion. This does not do any copying.
If you are sure that the slice is valid UTF-32, and you don’t want to incur the overhead of
the validity check, there is an unsafe version of this function,
from_vec_unchecked
, which has the same behavior but skips
the check.
If you need a string slice, consider using Utf32Str::from_slice
instead.
The inverse of this method is into_vec
.
§Errors
Returns an error if the vector is not UTF-32 with a description as to why the provided
vector is not UTF-32. The error will contain the original Vec
that can be reclaimed with
into_vec
.
§Examples
use widestring::Utf32String;
let sparkle_heart = vec![0x1f496];
let sparkle_heart = Utf32String::from_vec(sparkle_heart).unwrap();
assert_eq!("💖", sparkle_heart);
With incorrect values that return an error:
use widestring::Utf32String;
let sparkle_heart = vec![0xd83d, 0xdc96]; // UTF-16 surrogates are invalid
assert!(Utf32String::from_vec(sparkle_heart).is_err());
Sourcepub fn from_slice_lossy(s: &[u32]) -> Cow<'_, Utf32Str>
pub fn from_slice_lossy(s: &[u32]) -> Cow<'_, Utf32Str>
Converts a slice of u32
data to a string, including invalid characters.
Since the given u32
slice may not be valid UTF-32, and Utf32String
requires that
it is always valid UTF-32, during the conversion this function replaces any invalid UTF-32
sequences with U+FFFD REPLACEMENT CHARACTER
, which
looks like this: �
If you are sure that the slice is valid UTF-32, and you don’t want to incur the overhead of
the conversion, there is an unsafe version of this function,
from_vec_unchecked
, which has the same behavior but skips
the checks.
This function returns a Cow<'_, Utf32Str>
. If the given slice is
invalid UTF-32, then we need to insert our replacement characters which will change the size
of the string, and hence, require an owned Utf32String
. But if it’s already valid
UTF-32, we don’t need a new allocation. This return type allows us to handle both cases.
§Examples
use widestring::Utf32String;
let sparkle_heart = vec![0x1f496];
let sparkle_heart = Utf32String::from_slice_lossy(&sparkle_heart);
assert_eq!(utf32str!("💖"), sparkle_heart);
With incorrect values that return an error:
use widestring::Utf32String;
let sparkle_heart = vec![0xd83d, 0xdc96]; // UTF-16 surrogates are invalid
let sparkle_heart = Utf32String::from_slice_lossy(&sparkle_heart);
assert_eq!(utf32str!("\u{fffd}\u{fffd}"), sparkle_heart);
Sourcepub unsafe fn from_ustring_unchecked(s: impl Into<U32String>) -> Self
pub unsafe fn from_ustring_unchecked(s: impl Into<U32String>) -> Self
Converts a wide string of undefined encoding to a UTF-32 string without checking that the string contains valid UTF-32.
See the safe version, from_ustring
, for more information.
§Safety
This function is unsafe because it does not check that the string passed to it is valid
UTF-32. If this constraint is violated, undefined behavior results as it is assumed the
Utf32String
is always valid UTF-32.
§Examples
use widestring::{U32String, Utf32String};
let sparkle_heart = vec![0x1f496];
let sparkle_heart = U32String::from_vec(sparkle_heart);
let sparkle_heart = unsafe { Utf32String::from_ustring_unchecked(sparkle_heart) };
assert_eq!("💖", sparkle_heart);
Sourcepub fn from_ustring(s: impl Into<U32String>) -> Result<Self, Utf32Error>
pub fn from_ustring(s: impl Into<U32String>) -> Result<Self, Utf32Error>
Converts a wide string of undefined encoding string into a UTF-32 string.
Not all strings of undefined encoding are valid to convert, since Utf32String
requires
that it is always valid UTF-32. This function checks to ensure that the string is valid
UTF-32, and then does the conversion. This does not do any copying.
If you are sure that the string is valid UTF-32, and you don’t want to incur the overhead of
the validity check, there is an unsafe version of this function,
from_ustring_unchecked
, which has the same behavior but
skips the check.
If you need a string slice, consider using Utf32Str::from_ustr
instead.
§Errors
Returns an error if the string is not UTF-32 with a description as to why the provided string is not UTF-32.
§Examples
use widestring::{U32String, Utf32String};
let sparkle_heart = vec![0x1f496];
let sparkle_heart = U32String::from_vec(sparkle_heart);
let sparkle_heart = Utf32String::from_ustring(sparkle_heart).unwrap();
assert_eq!("💖", sparkle_heart);
With incorrect values that return an error:
use widestring::{U32String, Utf32String};
let sparkle_heart = vec![0xd83d, 0xdc96]; // UTF-16 surrogates are invalid
let sparkle_heart = U32String::from_vec(sparkle_heart); // Valid for a U32String
assert!(Utf32String::from_ustring(sparkle_heart).is_err()); // But not for a Utf32String
Sourcepub fn from_ustr_lossy(s: &U32Str) -> Cow<'_, Utf32Str>
pub fn from_ustr_lossy(s: &U32Str) -> Cow<'_, Utf32Str>
Converts a wide string slice of undefined encoding to a UTF-32 string, including invalid characters.
Since the given string slice may not be valid UTF-32, and Utf32String
requires that
it is always valid UTF-32, during the conversion this function replaces any invalid UTF-32
sequences with U+FFFD REPLACEMENT CHARACTER
, which
looks like this: �
If you are sure that the slice is valid UTF-32, and you don’t want to incur the overhead of
the conversion, there is an unsafe version of this function,
from_ustring_unchecked
, which has the same behavior but
skips the checks.
This function returns a Cow<'_, Utf32Str>
. If the given slice is
invalid UTF-32, then we need to insert our replacement characters which will change the size
of the string, and hence, require an owned Utf32String
. But if it’s already valid
UTF-32, we don’t need a new allocation. This return type allows us to handle both cases.
§Examples
use widestring::{U32Str, Utf32String};
let sparkle_heart = vec![0x1f496];
let sparkle_heart = U32Str::from_slice(&sparkle_heart);
let sparkle_heart = Utf32String::from_ustr_lossy(sparkle_heart);
assert_eq!(utf32str!("💖"), sparkle_heart);
With incorrect values that return an error:
use widestring::{U32Str, Utf32String};
let sparkle_heart = vec![0xd83d, 0xdc96]; // UTF-16 surrogates are invalid
let sparkle_heart = U32Str::from_slice(&sparkle_heart);
let sparkle_heart = Utf32String::from_ustr_lossy(sparkle_heart);
assert_eq!(utf32str!("\u{fffd}\u{fffd}"), sparkle_heart);
Sourcepub unsafe fn from_ucstring_unchecked(s: impl Into<U32CString>) -> Self
pub unsafe fn from_ucstring_unchecked(s: impl Into<U32CString>) -> Self
Converts a wide C string to a UTF-32 string without checking that the string contains valid UTF-32.
The resulting string does not contain the nul terminator.
See the safe version, from_ucstring
, for more information.
§Safety
This function is unsafe because it does not check that the string passed to it is valid
UTF-32. If this constraint is violated, undefined behavior results as it is assumed the
Utf32String
is always valid UTF-32.
§Examples
use widestring::{U32CString, Utf32String};
let sparkle_heart = vec![0x1f496];
let sparkle_heart = U32CString::from_vec(sparkle_heart).unwrap();
let sparkle_heart = unsafe { Utf32String::from_ucstring_unchecked(sparkle_heart) };
assert_eq!("💖", sparkle_heart);
Sourcepub fn from_ucstring(s: impl Into<U32CString>) -> Result<Self, Utf32Error>
pub fn from_ucstring(s: impl Into<U32CString>) -> Result<Self, Utf32Error>
Converts a wide C string into a UTF-32 string.
The resulting string does not contain the nul terminator.
Not all wide C strings are valid to convert, since Utf32String
requires that
it is always valid UTF-32. This function checks to ensure that the string is valid UTF-32,
and then does the conversion. This does not do any copying.
If you are sure that the string is valid UTF-32, and you don’t want to incur the overhead of
the validity check, there is an unsafe version of this function,
from_ucstring_unchecked
, which has the same behavior but
skips the check.
If you need a string slice, consider using Utf32Str::from_ucstr
instead.
§Errors
Returns an error if the string is not UTF-32 with a description as to why the provided string is not UTF-32.
§Examples
use widestring::{U32CString, Utf32String};
let sparkle_heart = vec![0x1f496];
let sparkle_heart = U32CString::from_vec(sparkle_heart).unwrap();
let sparkle_heart = Utf32String::from_ucstring(sparkle_heart).unwrap();
assert_eq!("💖", sparkle_heart);
With incorrect values that return an error:
use widestring::{U32CString, Utf32String};
let sparkle_heart = vec![0xd83d, 0xdc96]; // UTF-16 surrogates are invalid
let sparkle_heart = U32CString::from_vec(sparkle_heart).unwrap(); // Valid for a U32CString
assert!(Utf32String::from_ucstring(sparkle_heart).is_err()); // But not for a Utf32String
Sourcepub fn from_ucstr_lossy(s: &U32CStr) -> Cow<'_, Utf32Str>
pub fn from_ucstr_lossy(s: &U32CStr) -> Cow<'_, Utf32Str>
Converts a wide C string slice of to a UTF-32 string, including invalid characters.
The resulting string does not contain the nul terminator.
Since the given string slice may not be valid UTF-32, and Utf32String
requires that
it is always valid UTF-32, during the conversion this function replaces any invalid UTF-32
sequences with U+FFFD REPLACEMENT CHARACTER
, which
looks like this: �
If you are sure that the slice is valid UTF-32, and you don’t want to incur the overhead of
the conversion, there is an unsafe version of this function,
from_ucstring_unchecked
, which has the same behavior but
skips the checks.
This function returns a Cow<'_, Utf32Str>
. If the given slice is
invalid UTF-32, then we need to insert our replacement characters which will change the size
of the string, and hence, require an owned Utf32String
. But if it’s already valid
UTF-32, we don’t need a new allocation. This return type allows us to handle both cases.
§Examples
use widestring::{U32CStr, Utf32String};
let sparkle_heart = vec![0x1f496, 0x0];
let sparkle_heart = U32CStr::from_slice(&sparkle_heart).unwrap();
let sparkle_heart = Utf32String::from_ucstr_lossy(sparkle_heart);
assert_eq!(utf32str!("💖"), sparkle_heart);
With incorrect values that return an error:
use widestring::{U32CStr, Utf32String};
let sparkle_heart = vec![0xd83d, 0xdc96, 0x0]; // UTF-16 surrogates are invalid
let sparkle_heart = U32CStr::from_slice(&sparkle_heart).unwrap();
let sparkle_heart = Utf32String::from_ucstr_lossy(sparkle_heart);
assert_eq!(utf32str!("\u{fffd}\u{fffd}"), sparkle_heart);
Sourcepub fn from_chars(s: impl Into<Vec<char>>) -> Self
pub fn from_chars(s: impl Into<Vec<char>>) -> Self
Converts a vector of char
s into a UTF-32 string.
Since char
s are always valid UTF-32, this is infallible and efficient.
If you need a string slice, consider using Utf32Str::from_char_slice
instead.
§Examples
use widestring::{U32CString, Utf32String};
let sparkle_heart = vec!['💖'];
let sparkle_heart = Utf32String::from_chars(sparkle_heart);
assert_eq!("💖", sparkle_heart);
Sourcepub fn truncate(&mut self, new_len: usize)
pub fn truncate(&mut self, new_len: usize)
Shortens this string to the specified length.
If new_len
is greater than the string’s current length, this has no effect.
Note that this method has no effect on the allocated capacity of the string.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("hello");
s.truncate(2);
assert_eq!("he", s);
Sourcepub fn pop(&mut self) -> Option<char>
pub fn pop(&mut self) -> Option<char>
Removes the last character from the string buffer and returns it.
Returns None
if this string is empty.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("foo");
assert_eq!(s.pop(), Some('o'));
assert_eq!(s.pop(), Some('o'));
assert_eq!(s.pop(), Some('f'));
assert_eq!(s.pop(), None);
Sourcepub fn remove(&mut self, idx: usize) -> char
pub fn remove(&mut self, idx: usize) -> char
Removes a char
from this string at an offset and returns it.
This is an O(n) operation, as it requires copying every element in the buffer.
§Panics
Panics if idx
is larger than or equal to the string’s length.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("foo");
assert_eq!(s.remove(1), 'o');
assert_eq!(s.remove(0), 'f');
assert_eq!(s.remove(0), 'o');
Sourcepub fn retain<F>(&mut self, f: F)
pub fn retain<F>(&mut self, f: F)
Retains only the characters specified by the predicate.
In other words, remove all characters c
such that f(c)
returns false
. This method
operates in place, visiting each character exactly once in the original order, and preserves
the order of the retained characters.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("f_o_ob_ar");
s.retain(|c| c != '_');
assert_eq!(s, "foobar");
Because the elements are visited exactly once in the original order, external state may be used to decide which elements to keep.
use widestring::Utf32String;
let mut s = Utf32String::from_str("abcde");
let keep = [false, true, true, false, true];
let mut iter = keep.iter();
s.retain(|_| *iter.next().unwrap());
assert_eq!(s, "bce");
Sourcepub fn insert(&mut self, idx: usize, ch: char)
pub fn insert(&mut self, idx: usize, ch: char)
Inserts a character into this string at an offset.
This is an O(n) operation as it requires copying every element in the buffer.
§Panics
Panics if idx
is larger than the string’s length.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::with_capacity(3);
s.insert(0, 'f');
s.insert(1, 'o');
s.insert(1, 'o');
assert_eq!("foo", s);
Sourcepub fn insert_utfstr(&mut self, idx: usize, string: &Utf32Str)
pub fn insert_utfstr(&mut self, idx: usize, string: &Utf32Str)
Inserts a UTF-32 string slice into this string at an offset.
This is an O(n) operation as it requires copying every element in the buffer.
§Panics
Panics if idx
is larger than the string’s length.
§Examples
use widestring::Utf32String;
let mut s = Utf32String::from_str("bar");
s.insert_utfstr(0, utf32str!("foo"));
assert_eq!("foobar", s);
Sourcepub fn split_off(&mut self, at: usize) -> Self
pub fn split_off(&mut self, at: usize) -> Self
Splits the string into two at the given index.
Returns a newly allocated string. self
contains elements [0, at), and the returned string
contains elements [at, len).
Note that the capacity of self
does not change.
§Panics
Panics if at
it is beyond the last code point of the string.
§Examples
use widestring::Utf32String;
let mut hello = Utf32String::from_str("Hello, World!");
let world = hello.split_off(7);
assert_eq!(hello, "Hello, ");
assert_eq!(world, "World!");
Sourcepub fn drain<R>(&mut self, range: R) -> DrainUtf32<'_> ⓘwhere
R: RangeBounds<usize>,
pub fn drain<R>(&mut self, range: R) -> DrainUtf32<'_> ⓘwhere
R: RangeBounds<usize>,
Creates a draining iterator that removes the specified range in the string and yields the
removed char
s.
Note: The element range is removed even if the iterator is not consumed until the end.
§Panics
Panics if the starting point or end point are out of bounds.
§Examples
Basic usage:
use widestring::Utf32String;
let mut s = Utf32String::from_str("α is alpha, β is beta");
let beta_offset = 12;
// Remove the range up until the β from the string
let t: Utf32String = s.drain(..beta_offset).collect();
assert_eq!(t, "α is alpha, ");
assert_eq!(s, "β is beta");
// A full range clears the string
s.drain(..);
assert_eq!(s, "");
Sourcepub fn replace_range<R>(&mut self, range: R, replace_with: &Utf32Str)where
R: RangeBounds<usize>,
pub fn replace_range<R>(&mut self, range: R, replace_with: &Utf32Str)where
R: RangeBounds<usize>,
Removes the specified range in the string, and replaces it with the given string.
The given string doesn’t need to be the same length as the range.
§Panics
Panics if the starting point or end point are out of bounds.
§Examples
Basic usage:
use widestring::{utf32str, Utf32String};
let mut s = Utf32String::from_str("α is alpha, β is beta");
let beta_offset = 12;
// Replace the range up until the β from the string
s.replace_range(..beta_offset, utf32str!("Α is capital alpha; "));
assert_eq!(s, "Α is capital alpha; β is beta");
Trait Implementations
Source§impl Add<&Utf32Str> for Utf32String
impl Add<&Utf32Str> for Utf32String
Source§impl Add<&str> for Utf32String
impl Add<&str> for Utf32String
Source§impl AddAssign<&Utf32Str> for Utf32String
impl AddAssign<&Utf32Str> for Utf32String
Source§fn add_assign(&mut self, rhs: &Utf32Str)
fn add_assign(&mut self, rhs: &Utf32Str)
+=
operation. Read moreSource§impl AddAssign<&str> for Utf32String
impl AddAssign<&str> for Utf32String
Source§fn add_assign(&mut self, rhs: &str)
fn add_assign(&mut self, rhs: &str)
+=
operation. Read moreSource§impl AsMut<[char]> for Utf32String
impl AsMut<[char]> for Utf32String
Source§impl AsMut<Utf32Str> for Utf32String
impl AsMut<Utf32Str> for Utf32String
Source§impl AsRef<[char]> for Utf32String
impl AsRef<[char]> for Utf32String
Source§impl AsRef<[u32]> for Utf32String
impl AsRef<[u32]> for Utf32String
Source§impl AsRef<U32Str> for Utf32String
impl AsRef<U32Str> for Utf32String
Source§impl AsRef<Utf32Str> for Utf32String
impl AsRef<Utf32Str> for Utf32String
Source§impl Borrow<Utf32Str> for Utf32String
impl Borrow<Utf32Str> for Utf32String
Source§impl BorrowMut<Utf32Str> for Utf32String
impl BorrowMut<Utf32Str> for Utf32String
Source§fn borrow_mut(&mut self) -> &mut Utf32Str
fn borrow_mut(&mut self) -> &mut Utf32Str
Source§impl Clone for Utf32String
impl Clone for Utf32String
Source§fn clone(&self) -> Utf32String
fn clone(&self) -> Utf32String
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for Utf32String
impl Debug for Utf32String
Source§impl Default for Utf32String
impl Default for Utf32String
Source§fn default() -> Utf32String
fn default() -> Utf32String
Source§impl Deref for Utf32String
impl Deref for Utf32String
Source§impl DerefMut for Utf32String
impl DerefMut for Utf32String
Source§impl Display for Utf32String
impl Display for Utf32String
Source§impl<'a> Extend<&'a Utf32Str> for Utf32String
impl<'a> Extend<&'a Utf32Str> for Utf32String
Source§fn extend<T: IntoIterator<Item = &'a Utf32Str>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = &'a Utf32Str>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl<'a> Extend<&'a char> for Utf32String
impl<'a> Extend<&'a char> for Utf32String
Source§fn extend<T: IntoIterator<Item = &'a char>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = &'a char>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl<'a> Extend<&'a str> for Utf32String
impl<'a> Extend<&'a str> for Utf32String
Source§fn extend<T: IntoIterator<Item = &'a str>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = &'a str>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl Extend<Box<Utf32Str>> for Utf32String
impl Extend<Box<Utf32Str>> for Utf32String
Source§fn extend<T: IntoIterator<Item = Box<Utf32Str>>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Box<Utf32Str>>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl<'a> Extend<Cow<'a, Utf32Str>> for Utf32String
impl<'a> Extend<Cow<'a, Utf32Str>> for Utf32String
Source§fn extend<T: IntoIterator<Item = Cow<'a, Utf32Str>>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Cow<'a, Utf32Str>>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl Extend<String> for Utf32String
impl Extend<String> for Utf32String
Source§fn extend<T: IntoIterator<Item = String>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = String>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl Extend<Utf32String> for Utf32String
impl Extend<Utf32String> for Utf32String
Source§fn extend<T: IntoIterator<Item = Utf32String>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Utf32String>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)Source§impl Extend<char> for Utf32String
impl Extend<char> for Utf32String
Source§fn extend<T: IntoIterator<Item = char>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = char>>(&mut self, iter: T)
Source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)Source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)