From a4530a981342d92a0a5226a87734753d60d56f93 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Tue, 11 Sep 2018 16:29:13 +0200 Subject: Make XML tree a double-linked-list (significant improvement on previous node lookup) --- src/xml/simple-node.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/xml/simple-node.h') diff --git a/src/xml/simple-node.h b/src/xml/simple-node.h index d7ea1f16d..97e0b1d89 100644 --- a/src/xml/simple-node.h +++ b/src/xml/simple-node.h @@ -62,6 +62,8 @@ public: Node *next() override { return _next; } Node const *next() const override { return _next; } + Node *prev() override { return _prev; } + Node const *prev() const override { return _prev; } Node *firstChild() override { return _first_child; } Node const *firstChild() const override { return _first_child; } @@ -139,6 +141,7 @@ private: SimpleNode *_parent; SimpleNode *_next; + SimpleNode *_prev; Document *_document; mutable unsigned _cached_position; -- cgit v1.2.3