pub struct TextPosition {
pub start: u32,
pub end: u32,
}Expand description
A text position in a YAML document, represented as byte offsets.
Fields§
§start: u32The start byte offset
end: u32The end byte offset (exclusive)
Implementations§
Trait Implementations§
Source§impl Clone for TextPosition
impl Clone for TextPosition
Source§fn clone(&self) -> TextPosition
fn clone(&self) -> TextPosition
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TextPosition
impl Debug for TextPosition
Source§impl From<TextPosition> for TextRange
impl From<TextPosition> for TextRange
Source§fn from(pos: TextPosition) -> Self
fn from(pos: TextPosition) -> Self
Converts to this type from the input type.
Source§impl From<TextRange> for TextPosition
impl From<TextRange> for TextPosition
Source§impl Hash for TextPosition
impl Hash for TextPosition
Source§impl PartialEq for TextPosition
impl PartialEq for TextPosition
impl Copy for TextPosition
impl Eq for TextPosition
impl StructuralPartialEq for TextPosition
Auto Trait Implementations§
impl Freeze for TextPosition
impl RefUnwindSafe for TextPosition
impl Send for TextPosition
impl Sync for TextPosition
impl Unpin for TextPosition
impl UnsafeUnpin for TextPosition
impl UnwindSafe for TextPosition
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more