From b6ab7deb63d3e3e22ecd4d6c70c6249db2ba558c Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sat, 19 May 2007 02:58:38 +0000 Subject: Completely revised the way XPath expressions are calculated. --- src/node.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/node.h') diff --git a/src/node.h b/src/node.h index 2a137e86..7b1f9919 100644 --- a/src/node.h +++ b/src/node.h @@ -87,12 +87,12 @@ public: parent_node_t& as_parent_node() { if (! is_parent_node()) throw_(std::logic_error, "Request to cast leaf node to a parent node"); - return *polymorphic_downcast(this); + return downcast(*this); } const parent_node_t& as_parent_node() const { if (! is_parent_node()) throw_(std::logic_error, "Request to cast leaf node to a parent node"); - return *polymorphic_downcast(this); + return downcast(*this); } virtual value_t to_value() const = 0; @@ -116,6 +116,7 @@ public: attributes = attributes_t(); attributes->push_back(attr_pair(_name_id, value)); } + optional get_attr(const string& _name) const; optional get_attr(const nameid_t _name_id) const { if (attributes) { typedef attributes_t::nth_index<1>::type attributes_by_name; -- cgit v1.2.3