MCPcopy Create free account
hub / github.com/GraphLite-AI/GraphLite / from_positional

Method from_positional

graphlite/src/exec/result.rs:191–204  ·  view source on GitHub ↗

Create a row from positional values with variable names

(values: Vec<Value>, variables: &[String])

Source from the content-addressed store, hash-verified

189
190 /// Create a row from positional values with variable names
191 pub fn from_positional(values: Vec<Value>, variables: &[String]) -> Self {
192 let mut named_values = HashMap::new();
193 for (value, var_name) in values.iter().zip(variables.iter()) {
194 named_values.insert(var_name.clone(), value.clone());
195 }
196
197 Self {
198 values: named_values,
199 positional_values: values,
200 source_entities: HashMap::new(),
201 text_score: None,
202 highlight_snippet: None,
203 }
204 }
205
206 /// Set text search score
207 pub fn set_text_score(&mut self, score: f64) {

Callers

nothing calls this directly

Calls 3

cloneMethod · 0.80
iterMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected