net.sf.saxon.event

Class DocumentValidator

public class DocumentValidator extends ProxyReceiver

DocumentValidator checks that a document is well-formed: specifically, that it contains a single element node child and no text node children.
Field Summary
booleanfoundElement
intlevel
Method Summary
voidcharacters(CharSequence chars, int locationId, int properties)
Character data
voidendDocument()
Notify the end of a document node
voidendElement()
End of element
voidsetPipelineConfiguration(PipelineConfiguration config)
voidstartElement(int nameCode, int typeCode, int locationId, int properties)
Start of an element

Field Detail

foundElement

boolean foundElement

level

int level

Method Detail

characters

public void characters(CharSequence chars, int locationId, int properties)
Character data

endDocument

public void endDocument()
Notify the end of a document node

endElement

public void endElement()
End of element

setPipelineConfiguration

public void setPipelineConfiguration(PipelineConfiguration config)

startElement

public void startElement(int nameCode, int typeCode, int locationId, int properties)
Start of an element

Parameters: nameCode typeCode locationId properties

Throws: XPathException