[YANGTOOLS-1181] Update StoreTreeNode methods Created: 22/Nov/20  Updated: 10/Apr/22  Resolved: 22/Nov/20

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

Type: Improvement 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.api.schema.tree.StoreTreeNode.getChild() is forcing users to deal with optionals, where a lot of the time they would prefer to deal with a plain nullable.

Update StoreTreeNode so that it has three methods:

@Nullable TreeNode childByArg(PathArgument);

@NonNull TreeNode getChildByArg(PathArgument); // throws VerifyException

Optional<TreeNode> findChildByArg(PathArgument);

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