mirror of
https://github.com/jezhiggins/arabica
synced 2025-01-29 08:36:45 +01:00
gcc4 fixes
This commit is contained in:
parent
16a95885ca
commit
655a906071
2 changed files with 12 additions and 11 deletions
|
@ -13,32 +13,32 @@ class Parser : public SAX2DOM::Parser<stringT, string_adaptorT, SAX_parser>
|
|||
{
|
||||
typedef SAX2DOM::Parser<stringT, string_adaptorT, SAX_parser> BaseT;
|
||||
public:
|
||||
typedef boost::function2<void, DOM::Node<stringT> &, DOM::Node<stringT> &> ElementHandlerT;
|
||||
typedef boost::function2<void, DOM::Node<stringT> &, DOM::Node<stringT> &> ElementHandlerT;
|
||||
|
||||
void setElementEndHandler(ElementHandlerT func)
|
||||
{
|
||||
elementEndFunc_ = func;
|
||||
} // setElementEndHandler
|
||||
{
|
||||
elementEndFunc_ = func;
|
||||
} // setElementEndHandler
|
||||
|
||||
protected:
|
||||
virtual void endElement(const stringT& namespaceURI, const stringT& localName,
|
||||
const stringT& qName)
|
||||
{
|
||||
if(currentNode() == 0)
|
||||
if(BaseT::currentNode() == 0)
|
||||
return;
|
||||
|
||||
DOM::Node<stringT> child(currentNode());
|
||||
DOM::Node<stringT> child(BaseT::currentNode());
|
||||
|
||||
BaseT::endElement(namespaceURI, localName, qName);
|
||||
|
||||
if(!!elementEndFunc_)
|
||||
elementEndFunc_(currentNode(), child);
|
||||
if(!!elementEndFunc_)
|
||||
elementEndFunc_(BaseT::currentNode(), child);
|
||||
} // endElement
|
||||
|
||||
private:
|
||||
ElementHandlerT elementEndFunc_;
|
||||
ElementHandlerT elementEndFunc_;
|
||||
}; // class Parser
|
||||
|
||||
} // namespace DualMode
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
@ -65,4 +65,5 @@ class escaper
|
|||
|
||||
} // namespace XML
|
||||
} // namespace Arabica
|
||||
#endif // ARABICA_UTILS_ESCAPER_HPP
|
||||
#endif // ARABICA_UTILS_ESCAPER_HPP
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue