Kbase P98385: Is it possible to skip the parsing of a particular XML element based upon a certain condition using
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  07/12/2004 |
|
Status: Unverified
GOAL:
Is it possible to skip the parsing of a particular XML element based upon a certain condition using SAX in the 4GL?
GOAL:
Is there any way with the 4GL SAX-READER to tell the reader to skip elements?
GOAL:
How to make the XML parser skip processing of a specific XML element using SAX?
FIX:
The short answer is NO. There is no way with the SAX-READER to tell the reader to skip elements. This would need to be done by the 4GL developer. The developer in the StartElement callback would need to detect what is the particular element whose child nodes should not be parsed. Then, she/he would need to set some global variable that could be picked up by the Characters callback procedure. This variable would inform the Characters callback that it should skip processing. The programmer would need to clear this flag when it received the corresponding EndElement.