[−][src]Trait jsonc_parser::common::Ranged
Represents an object that has a range in the text.
Required methods
Loading content...Provided methods
fn start(&self) -> usize
Gets the index of the first character in the text.
fn start_line(&self) -> usize
Gets the line number of the start position in the text.
fn end(&self) -> usize
Gets the index after the last character in the text.
fn end_line(&self) -> usize
Gets the line number of the end position in the text.
fn text<'a>(&self, text: &'a str) -> &'a str
Gets the text from the provided string.
fn start_position(&self) -> Position
Gets the start position.
fn end_position(&self) -> Position
Gets the end position.
fn width(&self) -> usize
Gets the end position minus the start of the range.