MCPcopy Create free account
hub / github.com/PHPantom-dev/phpantom_lsp / get_classes_for_uri

Method get_classes_for_uri

src/util.rs:1554–1559  ·  view source on GitHub ↗

Public helper for tests: get the uri_classes_index entry for a given URI.

(&self, uri: &str)

Source from the content-addressed store, hash-verified

1552
1553 /// Public helper for tests: get the uri_classes_index entry for a given URI.
1554 pub fn get_classes_for_uri(&self, uri: &str) -> Option<Vec<ClassInfo>> {
1555 self.uri_classes_index
1556 .read()
1557 .get(uri)
1558 .map(|classes| classes.iter().map(|c| ClassInfo::clone(c)).collect())
1559 }
1560
1561 /// Gather the per-file context (classes, use-map, namespace) in one call.
1562 ///

Calls 3

iterMethod · 0.80
mapMethod · 0.45
getMethod · 0.45