MCPcopy Create free account
hub / github.com/AmrDeveloper/GQL / compare

Method compare

crates/gitql-core/src/values/text.rs:47–52  ·  view source on GitHub ↗
(&self, other: &Box<dyn Value>)

Source from the content-addressed store, hash-verified

45 }
46
47 fn compare(&self, other: &Box<dyn Value>) -> Option<Ordering> {
48 if let Some(other_text) = other.as_any().downcast_ref::<TextValue>() {
49 return self.value.partial_cmp(&other_text.value);
50 }
51 None
52 }
53
54 fn data_type(&self) -> Box<dyn DataType> {
55 Box::new(TextType)

Callers

nothing calls this directly

Calls 2

as_anyMethod · 0.45
partial_cmpMethod · 0.45

Tested by

no test coverage detected