pub enum CandidateSourceKind {
Generator(Arc<dyn CandidateGenerator>),
PreSupplied(Arc<Vec<RawCandidate>>),
}Expand description
How candidates flow into the pipeline. Picker calls have two
shapes (per the LSP cross-check): synchronous enumeration
(gen:files walks the FS per filter) vs. push-from-async
(LSP picker host-builds rows from an async response before
opening the picker).
Variants§
Generator(Arc<dyn CandidateGenerator>)
Pull-based — generate(ctx) runs per Pipeline::run.
First-party uses: Files, Buffers, Commands, Lines,
Jumps, Marks, Registers, Outline, RecentFiles. Plugin
uses: anything synchronously enumerable.
PreSupplied(Arc<Vec<RawCandidate>>)
Push-based — caller supplies the candidate set up front (typically from an async response). The pipeline treats the supplied Vec as a fixed input and runs only the match + rank + annotate stages. First-party uses: every LSP picker (references / definitions / completion / code-actions / code-lens / color-presentation / instances / show-message-request). Plugin uses: anything async / network-driven.
Trait Implementations§
Source§impl Clone for CandidateSourceKind
impl Clone for CandidateSourceKind
Source§fn clone(&self) -> CandidateSourceKind
fn clone(&self) -> CandidateSourceKind
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more