[YANGTOOLS-882] Cleanup ModificationApplyOperation.verifyStructure confusion Created: 21/May/18  Updated: 05/Jan/24

Status: Confirmed
Project: yangtools
Component/s: None
Affects Version/s: None
Fix Version/s: 14.0.0

Type: Improvement Priority: Medium
Reporter: Robert Varga Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

ModificationApplyOperation.verifyStructure() has a slightly unclear contract and has an unclear relationship with ModificationApplyOperation.recursivelyVerifyStructure().

There are two things that need to happen:

  • verifyChildren=true needs to be split into a new method, which will throw a checked exception
  • recursivelyVerifyStructure() needs to have its contract documented

For reasoning see:

  • AbstractNodeContainerModificationStrategy implementation of both methods – which share majority of the code
  • MinMaxElementsValidation and MandatoryLeafEnforcer.enforceOnData() callers, who could use the ability to report a DataValidationFailedException (and requisite context where we are in the data tree)

 


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