MCPcopy Create free account
hub / github.com/emwalker/digraph / appears_in

Method appears_in

backend/src/git/client.rs:117–134  ·  view source on GitHub ↗
(
        &self,
        repo_id: RepoId,
        search: &Search,
        entry: &SearchEntry,
    )

Source from the content-addressed store, hash-verified

115 }
116
117 pub fn appears_in(
118 &self,
119 repo_id: RepoId,
120 search: &Search,
121 entry: &SearchEntry,
122 ) -> Result<bool> {
123 for token in &search.tokens {
124 let key = repo_id.index_key(token)?;
125 if !key
126 .token_index(self, IndexMode::Update)?
127 .indexed_on(entry, token)?
128 {
129 return Ok(false);
130 }
131 }
132
133 Ok(true)
134 }
135
136 // How to handle path visibility?
137 fn cycle_exists(

Callers

nothing calls this directly

Calls 3

index_keyMethod · 0.80
indexed_onMethod · 0.80
token_indexMethod · 0.80

Tested by

no test coverage detected