pub struct IncludeResolution { /* private fields */ }Expand description
A partial or complete depth-first traversal of caller-authorized Compose includes.
Implementations§
Source§impl IncludeResolution
impl IncludeResolution
Sourcepub fn load(root: IncludedProjectInput, loader: &dyn IncludeLoader) -> Self
pub fn load(root: IncludedProjectInput, loader: &dyn IncludeLoader) -> Self
Loads and traverses one root project in depth-first effective-include order.
Each node uses the established ordered loader, then an authored no-interpolation merge and native project view before child declarations are considered. The returned graph remains inspectable after loader denials, loader failures, malformed declarations, duplicate source identifiers, cycles, or malformed project inputs. Resources from children are never merged or imported into their parents.
Sourcepub const fn root(&self) -> &IncludeIdentity
pub const fn root(&self) -> &IncludeIdentity
Returns the root identity selected by the caller.
Sourcepub fn nodes(&self) -> &[IncludeNode]
pub fn nodes(&self) -> &[IncludeNode]
Returns visited project occurrences in depth-first traversal order.
Sourcepub fn edges(&self) -> &[IncludeEdge]
pub fn edges(&self) -> &[IncludeEdge]
Returns successful loader edges in request order.
Sourcepub fn requests(&self) -> &[IncludeRequest]
pub fn requests(&self) -> &[IncludeRequest]
Returns every effective declaration submitted to the caller’s loader in order.
Sourcepub fn diagnostics(&self) -> &[Diagnostic]
pub fn diagnostics(&self) -> &[Diagnostic]
Returns diagnostics from every reached loading, merge, view, and traversal boundary.
Sourcepub fn compose(&self) -> IncludeCompositionResult
pub fn compose(&self) -> IncludeCompositionResult
Composes already loaded child occurrences without authorizing further loading or performing I/O.
The pass first composes every non-cycle child recursively, then imports absent definitions into each parent after that parent’s ordinary multi-file merge. Same-namespace same-name candidates remain separate conflict records and never enter ordinary Compose merge rules.
Sourcepub fn plan_project_directories(
&self,
resolver: &dyn IncludeProjectDirectoryResolver,
) -> IncludeProjectDirectoryPlan
pub fn plan_project_directories( &self, resolver: &dyn IncludeProjectDirectoryResolver, ) -> IncludeProjectDirectoryPlan
Plans effective include project directories through an explicit caller-owned resolver.
Only explicit project_directory declarations invoke the resolver. Root and child defaults
reuse the caller-supplied first-document directories already retained by the traversal.
Trait Implementations§
Source§impl Clone for IncludeResolution
impl Clone for IncludeResolution
Source§fn clone(&self) -> IncludeResolution
fn clone(&self) -> IncludeResolution
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more