Trait lsp_document::TextMap [−][src]
pub trait TextMap {
fn text(&self) -> &str;
fn offset_to_pos(&self, offset: usize) -> Option<Pos>;
fn line_range(&self, line: u32) -> Option<Range<Pos>>;
fn substr(&self, range: Range<Pos>) -> Option<&str>;
fn offset_range_to_range(&self, offsets: Range<usize>) -> Option<Range<Pos>> { ... }
}