- List of tags (in same format as GetSupportedTags's return value). The parser
- will redirect these tags to handler (until call to PopTagHandler).
+ List of tags (in same format as GetSupportedTags()'s return value).
+ The parser will redirect these tags to handler (until call to PopTagHandler()).
+
+ Example:
+
+ Imagine you want to parse following pseudo-html structure:
+ @code
+ <myitems>
+ <param name="one" value="1">
+ <param name="two" value="2">
+ </myitems>
+
+ <execute>
+ <param program="text.exe">
+ </execute>
+ @endcode
+
+ It is obvious that you cannot use only one tag handler for \<param\> tag.
+ Instead you must use context-sensitive handlers for \<param\> inside \<myitems\>
+ and \<param\> inside \<execute\>.
+ This is the preferred solution:
+
+ @code
+ TAG_HANDLER_BEGIN(MYITEM, "MYITEMS")
+ TAG_HANDLER_PROC(tag)
+ {
+ // ...something...
+
+ m_Parser -> PushTagHandler(this, "PARAM");
+ ParseInner(tag);
+ m_Parser -> PopTagHandler();
+
+ // ...something...
+ }
+ TAG_HANDLER_END(MYITEM)
+ @endcode