[YANGTOOLS-1547] Add a minimalistic XML tree implementation Created: 06/Oct/23  Updated: 18/Jan/24

Status: Confirmed
Project: yangtools
Component/s: codecs, common, data-api
Affects Version/s: None
Fix Version/s: 13.0.2

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

Issue Links:
Blocks
blocks YANGTOOLS-994 Add support for JSON-encoded anydata Confirmed

 Description   

YANG's anydata is defined to be an YANG-modeled data formatted in transport encoding. We are using DOMSource to represent this data.

This is less than optimal, simply because DOMSource leaks Document/Element, both of which are mutable.

in both JSON and XML codecs, when we are dealing with a forward reference, we store encountered events into a String and re-parse them.

Both of these would do better if we had an object model for anydata contents. Once we have that, we can act it for buffering purposes.

Once we do, there is little doubt where AnydataNode is going: it is going to be unconditionally based on this internal object model.

Steps to completion:
1. Introduce a bare-minimum model of what constituates YANG-modeled XML data,
2. Define an anydata/anyxml representation nodes.
3. add binfmt support
4. add DOMSource -> XYZDocument translation



 Comments   
Comment by Robert Varga [ 06/Oct/23 ]

As a design note: this API should operate on String. While we could require XMLNamespace and Unqualified arguments, it does seem a bit pedantic.

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