Struct hypothesis::annotations::TextPositionSelector[][src]

pub struct TextPositionSelector {
    pub start: u64,
    pub end: u64,
}

This Selector describes a range of text by recording the start and end positions of the selection in the stream. Position 0 would be immediately before the first character, position 1 would be immediately before the second character, and so on. The start character is thus included in the list, but the end character is not.

For example, if the document was “abcdefghijklmnopqrstuvwxyz”, the start was 4, and the end was 7, then the selection would be “efg”. Web Annotation Data Model - Text Position Selector

Fields

start: u64

The starting position of the segment of text. The first character in the full text is character position 0, and the character is included within the segment.

end: u64

The end position of the segment of text. The character is not included within the segment.

Trait Implementations

impl Clone for TextPositionSelector[src]

impl Debug for TextPositionSelector[src]

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

impl PartialEq<TextPositionSelector> for TextPositionSelector[src]

impl Serialize for TextPositionSelector[src]

impl StructuralPartialEq for TextPositionSelector[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> 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<D> OwoColorize for D

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.