At present there's no established query language for a ThingyTree, apart from JSON.
Perhaps a ThingyTracker could keep an XML DOM in synchrony with the ThingyTree, and then XPath could be used to identify sets of actual DOM elements and a mapping maintained between the two. This means XPath doesn't have to be reinvented. It also provides a convenient serialisation strategy for ThingyTrees.
At present there's no established query language for a ThingyTree, apart from JSON.
Perhaps a ThingyTracker could keep an XML DOM in synchrony with the ThingyTree, and then XPath could be used to identify sets of actual DOM elements and a mapping maintained between the two. This means XPath doesn't have to be reinvented. It also provides a convenient serialisation strategy for ThingyTrees.