Text_Node(3) Text_Node(3) NAME Text_Node - Node in an HTML tree for plain text SYNOPSIS namespace HTML_Tree { class Text_Node : public HTML_Node { public: Text_Node( char const *new_text, Content_Node* = 0 ); Text_Node( char const *begin, char const *end, Content_Node *parent = 0 ); std::string text; protected: // overridden virtual bool similar_to( HTML_Node const& ) const; virtual bool write_node( std::ostream&, int, bool ) const; }; } DESCRIPTION Public Interface Text_Node is-an HTML_Node that simply contains plain text. Public Interface Text_Node( char const *new_text, Content_Node *parent = 0 ) Makes the given text the text. If parent is not null, sets the parent and adds this node to that parent's list of child nodes. Text_Node( char const *begin, char const *end, Con­ tent_Node *parent = 0 ) Constructor. It takes pointers to the beginning character and one past the end (in STL iterator style) and makes that the text. If parent is not null, sets the parent and adds this node to that parent's list of child nodes. string text The text. Protected Interface virtual bool similar_to( HTML_Node const& ) const Returns true only if the given node is a Text_Node and the text of both nodes is equal; false other­ wise. SEE ALSO Content_Node(3), HTML_Node(3). AUTHOR Paul J. Lucas HTML Tree March 17, 2003 Text_Node(3)