OOoRunner test harness

util
Class XMLTools.XMLChecker

util.XMLTools.XMLWriter
  |
  +--util.XMLTools.XMLWellFormChecker
        |
        +--util.XMLTools.XMLChecker
Enclosing class:
XMLTools

public static class XMLTools.XMLChecker
extends XMLTools.XMLWellFormChecker

Class realises extended XML data checking. It has possibilities to check if a tag exists, if it has some attributes with values, and if this tag is contained in another tag (which also can specify any attributes). It can check if some character data exists inside any tag specified.


Field Summary
protected  Vector attrStack
           
protected  Vector chars
           
protected  Vector tags
           
protected  HashSet tagSet
           
protected  Vector tagStack
           
 
Fields inherited from class util.XMLTools.XMLWellFormChecker
docEnded, docStarted, log, noOtherErrors, printXMLData, wellFormed
 
Constructor Summary
XMLTools.XMLChecker(PrintWriter log, boolean writeXML)
           
 
Method Summary
 void addCharacters(String ch)
           
 void addCharactersEnclosed(String ch, XMLTools.Tag outerTag)
           
 void addTag(XMLTools.Tag tag)
           
 void addTagEnclosed(XMLTools.Tag tag, XMLTools.Tag outerTag)
           
 void characters(String ch)
           
 boolean check()
           
 void endElement(String name)
           
 void startElement(String name, com.sun.star.xml.sax.XAttributeList attr)
           
 
Methods inherited from class util.XMLTools.XMLWellFormChecker
endDocument, isWellFormed, printError, reset, startDocument
 
Methods inherited from class util.XMLTools.XMLWriter
ignorableWhitespace, processingInstruction, setDocumentLocator
 

Field Detail

tagSet

protected HashSet tagSet

tags

protected Vector tags

chars

protected Vector chars

tagStack

protected Vector tagStack

attrStack

protected Vector attrStack
Constructor Detail

XMLTools.XMLChecker

public XMLTools.XMLChecker(PrintWriter log,
                           boolean writeXML)
Method Detail

addTag

public void addTag(XMLTools.Tag tag)

addTagEnclosed

public void addTagEnclosed(XMLTools.Tag tag,
                           XMLTools.Tag outerTag)

addCharacters

public void addCharacters(String ch)

addCharactersEnclosed

public void addCharactersEnclosed(String ch,
                                  XMLTools.Tag outerTag)

startElement

public void startElement(String name,
                         com.sun.star.xml.sax.XAttributeList attr)
Overrides:
startElement in class XMLTools.XMLWellFormChecker

characters

public void characters(String ch)
Overrides:
characters in class XMLTools.XMLWriter

endElement

public void endElement(String name)
Overrides:
endElement in class XMLTools.XMLWellFormChecker

check

public boolean check()

OOoRunner test harness