pub enum SymbolKey {
Global {
scheme: String,
package: Package,
descriptors: Vec<Descriptor>,
},
Local(String),
}Variants§
Implementations§
Source§impl SymbolKey
impl SymbolKey
Sourcepub fn new(language: &LanguageId) -> SymbolKey
pub fn new(language: &LanguageId) -> SymbolKey
Root key of a Model frontend for language: model <language> . . .
Sourcepub fn child(&self, d: Descriptor) -> SymbolKey
pub fn child(&self, d: Descriptor) -> SymbolKey
This key extended with d (a local key is returned unchanged).
Sourcepub fn for_file(language: &LanguageId, path: &str) -> SymbolKey
pub fn for_file(language: &LanguageId, path: &str) -> SymbolKey
Key of a source file: one namespace per path segment, as
scip-typescript names modules (src/a.ts/).
pub fn descriptors(&self) -> &[Descriptor]
Sourcepub fn same_descriptors(&self, other: &SymbolKey) -> bool
pub fn same_descriptors(&self, other: &SymbolKey) -> bool
Same descriptors, whatever the scheme and package: how a key built from syntax meets the key a SCIP indexer gave the same symbol.
pub fn parse(s: &str) -> Result<SymbolKey, KeyError>
Trait Implementations§
impl Eq for SymbolKey
impl StructuralPartialEq for SymbolKey
Auto Trait Implementations§
impl Forget for SymbolKey
impl Freeze for SymbolKey
impl Move for SymbolKey
impl RefUnwindSafe for SymbolKey
impl Send for SymbolKey
impl Sync for SymbolKey
impl Unpin for SymbolKey
impl UnsafeUnpin for SymbolKey
impl UnwindSafe for SymbolKey
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