pub struct DocumentSymbol {
pub children: Option<Vec<DocumentSymbol>>,
pub deprecated: Option<bool>,
pub detail: Option<String>,
pub kind: SymbolKind,
pub name: String,
pub range: Range,
pub selection_range: Range,
pub tags: Option<Vec<SymbolTag>>,
}Expand description
Represents programming constructs like variables, classes, interfaces etc. that appear in a document. Document symbols can be hierarchical and they have two ranges: one that encloses its definition and one that points to its most interesting range, e.g. the range of an identifier.
Fields§
§children: Option<Vec<DocumentSymbol>>Children of this symbol, e.g. properties of a class.
deprecated: Option<bool>Indicates if this symbol is deprecated.
detail: Option<String>More detail for this symbol, e.g the signature of a function.
kind: SymbolKindThe kind of this symbol.
name: StringThe name of this symbol. Will be displayed in the user interface and therefore must not be an empty string or a string only consisting of white spaces.
range: RangeThe range enclosing this symbol not including leading/trailing whitespace but everything else like comments. This information is typically used to determine if the clients cursor is inside the symbol to reveal in the symbol in the UI.
selection_range: RangeThe range that should be selected and revealed when this symbol is being picked, e.g. the
name of a function. Must be contained by the range.
Tags for this document symbol.
Trait Implementations§
Source§impl Clone for DocumentSymbol
impl Clone for DocumentSymbol
Source§fn clone(&self) -> DocumentSymbol
fn clone(&self) -> DocumentSymbol
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more