Skip to main content

Module string

Module string 

Source
Expand description

String-related utilities and extension traits.

Re-exports§

pub use bounded_buffer::BoundedBuffer;
pub use trim::TrimExt;

Modules§

bounded_buffer
highlighted
Provides the HighlightedText utility which expresses the idea of a piece of text with highlight markers.
trim

Structs§

Blank
The error returned when a string is empty or all whitespace.
ContainsNul
The error returned when a string contains a NUL byte.
NonBlank
A string with at least one non-whitespace character, held verbatim. T is any string type: String, &str, Cow<str>, Box<str>, …
NonNulStr
A string proven to contain no NUL byte.

Traits§

EscapeNonPrintablePosixExt
Extension trait for anything that can behave like a string to make it easy to escape control characters into a printable, cat -v-style representation.
FormatSafeUrlExt
Extension trait for Url to render a Debug representation with any password redacted.
NonEmptyOrExt
Extension trait for owned strings providing an empty-string fallback.
NormalizeDiacriticsExt
Extension trait adding diacritic normalization to string slices.
TruncateCharsExt

Functions§

normalize
Normalize a Unicode character by converting Latin characters which are variants of ASCII characters to their latin equivalent.

Type Aliases§

NonBlankString