pub struct StdioProvider { /* private fields */ }Implementations§
Source§impl StdioProvider
impl StdioProvider
Sourcepub fn spawn(command: &[String], timeout: Duration) -> ProviderResult<Self>
pub fn spawn(command: &[String], timeout: Duration) -> ProviderResult<Self>
Spawn the provider and run the initialize handshake.
Sourcepub fn spawn_with_stderr(
command: &[String],
timeout: Duration,
inherit_stderr: bool,
) -> ProviderResult<Self>
pub fn spawn_with_stderr( command: &[String], timeout: Duration, inherit_stderr: bool, ) -> ProviderResult<Self>
Spawn with the configured stderr policy (plans/0008 §4):
Inherit passes the child’s stderr through for adapter
debugging; anything else discards it.
Sourcepub fn spawn_with_cache(
command: &[String],
timeout: Duration,
inherit_stderr: bool,
cache_bytes: u64,
cache_dir: Option<PathBuf>,
) -> ProviderResult<Self>
pub fn spawn_with_cache( command: &[String], timeout: Duration, inherit_stderr: bool, cache_bytes: u64, cache_dir: Option<PathBuf>, ) -> ProviderResult<Self>
Spawn with the user’s cache budget and the provider’s subtree path — both travel in every initialize (protocol v1.2, advisory).
Sourcepub fn spawn_with_env(
command: &[String],
timeout: Duration,
env: &[(&str, &str)],
) -> ProviderResult<Self>
pub fn spawn_with_env( command: &[String], timeout: Duration, env: &[(&str, &str)], ) -> ProviderResult<Self>
Spawn with extra environment for the child process — the test-binary re-exec seam (fakes pick their script by env).
Trait Implementations§
Source§impl Drop for StdioProvider
impl Drop for StdioProvider
Source§impl Provider for StdioProvider
impl Provider for StdioProvider
Source§fn search_code_progressive(
&self,
q: &str,
on_hits: &(dyn Fn(&[CodeMatch]) + Send + Sync),
) -> ProviderResult<SearchCodeResult>
fn search_code_progressive( &self, q: &str, on_hits: &(dyn Fn(&[CodeMatch]) + Send + Sync), ) -> ProviderResult<SearchCodeResult>
v1.3 progressive search (plans/0011): partial: true opts into
$/partial batches for this request’s id; the reply is
metadata-only when the provider streamed (items empty,
truncated authoritative).
Source§fn refs(&self, repo: &RepoId) -> ProviderResult<RepoRefs>
fn refs(&self, repo: &RepoId) -> ProviderResult<RepoRefs>
v1.5 (plans/0016 M1): branches + tags.
Source§fn log(
&self,
repo: &RepoId,
path: Option<&str>,
ref_: Option<&GitRef>,
limit: Option<usize>,
) -> ProviderResult<(Vec<LogEntry>, bool)>
fn log( &self, repo: &RepoId, path: Option<&str>, ref_: Option<&GitRef>, limit: Option<usize>, ) -> ProviderResult<(Vec<LogEntry>, bool)>
v1.5: commit log, newest first.
Source§fn blob_at(
&self,
repo: &RepoId,
path: &str,
ref_: Option<&GitRef>,
) -> ProviderResult<(Vec<u8>, Sha)>
fn blob_at( &self, repo: &RepoId, path: &str, ref_: Option<&GitRef>, ) -> ProviderResult<(Vec<u8>, Sha)>
v1.5: file bytes + content id at path@ref (open-at-commit).
Source§fn blame(
&self,
repo: &RepoId,
path: &str,
ref_: Option<&GitRef>,
) -> ProviderResult<Vec<BlameRange>>
fn blame( &self, repo: &RepoId, path: &str, ref_: Option<&GitRef>, ) -> ProviderResult<Vec<BlameRange>>
v1.5: blame ranges.
Source§fn commit(&self, repo: &RepoId, sha: &Sha) -> ProviderResult<CommitDetail>
fn commit(&self, repo: &RepoId, sha: &Sha) -> ProviderResult<CommitDetail>
v1.6 (plans/0028): one commit’s detail — the reply deserializes straight into the seam type (it already carries the wire defaults).
Source§fn advise_cancel(&self)
fn advise_cancel(&self)
v1.1 advisory cancel: name a request currently in flight, if any. Best-effort — a racing cancel for an id that just completed is ignored by the provider by contract.
Source§fn take_notice(&self) -> Option<String>
fn take_notice(&self) -> Option<String>
One-shot restart notice for the status line (plans/0008 §5).
Source§fn cache_usage(&self) -> Option<u64>
fn cache_usage(&self) -> Option<u64>
Cache usage reported at the initialize handshake, when the provider participates in the advisory budget (v1.2).
fn name(&self) -> &str
Source§fn icon(&self) -> Option<String>
fn icon(&self) -> Option<String>
icon, protocol v1.3);
the in-tree github provider owns the one rootle hardcodes.fn capabilities(&self) -> Capabilities
Source§fn search(&self, query: &str) -> ProviderResult<Vec<SearchItem>>
fn search(&self, query: &str) -> ProviderResult<Vec<SearchItem>>
Source§fn org_repos(&self, org: &str) -> ProviderResult<Vec<RepoInfo>>
fn org_repos(&self, org: &str) -> ProviderResult<Vec<RepoInfo>>
Source§fn fetch_tree(
&self,
repo: &RepoId,
ref_: Option<&GitRef>,
) -> ProviderResult<TreeResult>
fn fetch_tree( &self, repo: &RepoId, ref_: Option<&GitRef>, ) -> ProviderResult<TreeResult>
ref (branch/tag/sha) when
given (v1.5), else the default branch.Source§fn fetch_blob(&self, repo: &RepoId, sha: &Sha) -> ProviderResult<Vec<u8>>
fn fetch_blob(&self, repo: &RepoId, sha: &Sha) -> ProviderResult<Vec<u8>>
Source§fn web_url(
&self,
repo: &RepoId,
path: &str,
branch: Option<&GitRef>,
line: Option<u32>,
end: Option<u32>,
is_file: bool,
) -> ProviderResult<String>
fn web_url( &self, repo: &RepoId, path: &str, branch: Option<&GitRef>, line: Option<u32>, end: Option<u32>, is_file: bool, ) -> ProviderResult<String>
is_file picks the grammar (GitHub: blob vs tree); line
adds a fragment when Some. branch is None for the default
branch (the provider resolves it).Source§fn clone_url(&self, repo: &RepoId) -> ProviderResult<String>
fn clone_url(&self, repo: &RepoId) -> ProviderResult<String>
git clone accepts for a repo (clone wizard, plans/0004).Source§fn search_code(&self, q: &str) -> ProviderResult<SearchCodeResult>
fn search_code(&self, q: &str) -> ProviderResult<SearchCodeResult>
q is the full query string with qualifiers.