Maintain a SchemaInferenceStack in SchemaTracker
(YANGTOOLS-1233)
|
|
| Status: | Resolved |
| Project: | yangtools |
| Component/s: | model-util |
| Affects Version/s: | None |
| Fix Version/s: | 7.0.0 |
| Type: | Sub-task | Priority: | Medium |
| Reporter: | Robert Varga | Assignee: | Robert Varga |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
yang-data-impl's SchemaTracker performs a rather weird dance, where (due to NormalizedNode) hierarchy it performs a hybrid schema tree/data tree walk. While it can enter a ChoiceEffectiveStatement via schema tree, it needs to deal with choice/case/choice traversal, where it does not see the intermediate case. SchemaInferenceStack is well equipped to handle this, as it already needs to deal with choice/case crossing during SchemaNodeIdentifier construction when data tree steps are involved. Introduce an alternative enterChoice(QName), which will examine parent and based on that either turns into a enterSchemaTree() or, if parent is a Choice, will do a case traversal search – resulting in a clean=false step which resolveSchemaTreeSteps() needs to unwind. |