doc.rust-lang.org
pub struct MatchIndices<'a, P>
Created with the method match_indices.
struct
core
Stable since 1.5.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct LinesAny<'a>
Created with the method lines_any.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Lines<'a>
An iterator over the lines of a string, as string slices.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct EscapeUnicode<'a>
The return type of str::escape_unicode.
struct
core
Stable since 1.34.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct EscapeDefault<'a>
The return type of str::escape_default.
struct
core
Stable since 1.34.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct EscapeDebug<'a>
The return type of str::escape_debug.
struct
core
Stable since 1.34.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct EncodeUtf16<'a>
An iterator of u16 over the string encoded as UTF-16.
struct
core
Stable since 1.8.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn as_str(&self) -> &'a str
Views the underlying data as a subslice of the original data.
method
core
Stable since 1.4.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Chars<'a>
An iterator over the chars of a string slice.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn offset(&self) -> usize
Returns the byte position of the next character, or the length of the underlying string if there are no more characters.
method
core
Stable since 1.82.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn as_str(&self) -> &'a str
Views the underlying data as a subslice of the original data.
method
core
Stable since 1.4.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct CharIndices<'a>
An iterator over the chars of a string slice, and their positions.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Bytes<'a>
An iterator over the bytes of a string slice.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn is_empty(&self) -> bool
Returns true if self has a length of zero bytes.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn is_char_boundary(&self, index: usize) -> bool
Checks that index-th byte is the first byte in a UTF-8 code point sequence or the end of the string.
method
core
Stable since 1.9.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn is_ascii(&self) -> bool
Checks if all characters in this string are within the ASCII range.
method
core
Stable since 1.23.0
Version 1.100.0-nightly
doc.rust-lang.org
pub unsafe fn get_unchecked_mut<I>(&mut self, i: I) -> &mut <I as >::Output
Returns a mutable, unchecked subslice of str.
method
core
Stable since 1.20.0
Version 1.100.0-nightly
doc.rust-lang.org
pub unsafe fn get_unchecked<I>(&self, i: I) -> &<I as >::Output
Returns an unchecked subslice of str.
method
core
Stable since 1.20.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn get_mut<I>(&mut self, i: I) -> Option<&mut <I as >::Output>
Returns a mutable subslice of str.
method
core
Stable since 1.20.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn get<I>(&self, i: I) -> Option<&<I as >::Output>
Returns a subslice of str.
method
core
Stable since 1.20.0
Version 1.100.0-nightly