Struct telexide::model::TextBlock[][src]

pub struct TextBlock {
    pub offset: usize,
    pub length: usize,
}

An object describing a part of a text

Fields

offset: usize

Offset in UTF-16 code units to the start of the entity

length: usize

Length of the entity in UTF-16 code units

Implementations

impl TextBlock[src]

pub fn get_text(&self, text: &str) -> String[src]

Gets the part of the text described by the TextBlock

Trait Implementations

impl Clone for TextBlock[src]

impl Debug for TextBlock[src]

impl<'de> Deserialize<'de> for TextBlock[src]

impl PartialEq<TextBlock> for TextBlock[src]

impl Serialize for TextBlock[src]

impl StructuralPartialEq for TextBlock[src]

Auto Trait Implementations

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> CloneAny for T where
    T: Any + Clone
[src]

impl<T> DebugAny for T where
    T: Any + Debug
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

impl<T> Instrument 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, 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.

impl<T> UnsafeAny for T where
    T: Any