Defer statement initialization in InferredStatementContext (YANGTOOLS-784)

[YANGTOOLS-1160] Improve InferredStatementContext on-demand instantiation Created: 29/Oct/20  Updated: 15/Mar/23  Resolved: 13/Nov/20

Status: Resolved
Project: yangtools
Component/s: parser
Affects Version/s: None
Fix Version/s: 7.0.0

Type: Sub-task Priority: Medium
Reporter: Robert Varga Assignee: Miroslav Kovac
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Blocks
is blocked by YANGTOOLS-1168 Introduce parser.spi.SchemaTreeNamespace Resolved
Relates
relates to YANGTOOLS-1480 Fail to process deviation/augmentatio... Resolved

 Description   

When we are faced for a query for a particular child, we really do not want to instantiate all children.

Given we can use logic from YANGTOOLS-1157, we can now precisely know which statement from the prototype we need when asked for a SchemaTreeEffectiveStatement's StmtContext.

Initialize only that child and remember that action in a Map. When it comes time to materialize children be mindful of any such instantiations which might have happened and skip those statements.


Generated at Wed Feb 07 20:55:21 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.