Struct cursive::utils::span::SpannedStr[][src]

pub struct SpannedStr<'a, T> where
    T: 'a, 
{ /* fields omitted */ }

The immutable, borrowed equivalent of SpannedString.

Methods

impl<'a, T> SpannedStr<'a, T> where
    T: 'a, 
[src]

Creates a new SpannedStr from the given references.

Important traits for Vec<u8>

Gives access to the parsed styled spans.

Important traits for &'a [u8]

Returns a reference to the indexed spans.

Returns a reference to the source (non-parsed) string.

Returns true if self is empty.

Can be caused by an empty source, or no span.

Trait Implementations

impl<'a, T: Debug> Debug for SpannedStr<'a, T> where
    T: 'a, 
[src]

Formats the value using the given formatter. Read more

impl<'a, T: PartialEq> PartialEq for SpannedStr<'a, T> where
    T: 'a, 
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<'a, T: Eq> Eq for SpannedStr<'a, T> where
    T: 'a, 
[src]

impl<'a, T> SpannedText for SpannedStr<'a, T> where
    T: 'a, 
[src]

Type of span returned by SpannedText::spans().

Returns the source text.

Important traits for &'a [u8]

Returns the spans for this text.

Returns a SpannedText by reference.

impl<'a, T> Clone for SpannedStr<'a, T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<'a, T> From<&'a SpannedString<T>> for SpannedStr<'a, T>
[src]

Performs the conversion.

Auto Trait Implementations

impl<'a, T> Send for SpannedStr<'a, T> where
    T: Sync

impl<'a, T> Sync for SpannedStr<'a, T> where
    T: Sync