pub struct LanguageIndex { /* private fields */ }Expand description
Index that groups code units by language.
Implementations§
Source§impl LanguageIndex
impl LanguageIndex
Sourcepub fn build(graph: &CodeGraph) -> Self
pub fn build(graph: &CodeGraph) -> Self
Build a LanguageIndex from all code units in the given graph.
Sourcepub fn lookup(&self, language: Language) -> &[u64]
pub fn lookup(&self, language: Language) -> &[u64]
Look up all unit IDs written in the given language.
Returns an empty slice if no units match.
Trait Implementations§
Source§impl Clone for LanguageIndex
impl Clone for LanguageIndex
Source§fn clone(&self) -> LanguageIndex
fn clone(&self) -> LanguageIndex
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 LanguageIndex
impl Debug for LanguageIndex
Source§impl Default for LanguageIndex
impl Default for LanguageIndex
Source§fn default() -> LanguageIndex
fn default() -> LanguageIndex
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LanguageIndex
impl RefUnwindSafe for LanguageIndex
impl Send for LanguageIndex
impl Sync for LanguageIndex
impl Unpin for LanguageIndex
impl UnsafeUnpin for LanguageIndex
impl UnwindSafe for LanguageIndex
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