1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//! Namespace resolution utilities for LSP handlers.
use Arc;
use LineIndex;
use Url;
use crateDocument;
use crateDocumentGraph;
/// Context for an imported document accessed through a namespace.
///
/// This struct provides convenient access to all the information needed when
/// resolving symbols in imported documents.
/// Gets the context for an imported document by its URI.
///
/// This is a convenience function that performs the common pattern of looking
/// up the source document in the graph and extracting the document and line
/// information.
///
/// Returns an [`ImportedDocContext`] if the document exists in the graph,
/// otherwise [`None`].