public abstract class AbstractNodeTester extends java.lang.Object implements NodeTester
NodeTest
Constructor and Description |
---|
AbstractNodeTester() |
Modifier and Type | Method and Description |
---|---|
void |
noMoreNodes(NodeTest forTest)
Validate that the Nodes validated one-by-one in the
isValid
method were all the Nodes expected. |
void |
testAttribute(org.w3c.dom.Attr attribute)
Template delegator for testNode() method.
|
void |
testCDATASection(org.w3c.dom.CDATASection cdata)
Template delegator for testNode() method.
|
void |
testComment(org.w3c.dom.Comment comment)
Template delegator for testNode() method.
|
void |
testDocumentType(org.w3c.dom.DocumentType doctype)
Template delegator for testNode() method.
|
void |
testElement(org.w3c.dom.Element element)
Template delegator for testNode() method.
|
void |
testEntity(org.w3c.dom.Entity entity)
Template delegator for testNode() method.
|
void |
testEntityReference(org.w3c.dom.EntityReference reference)
Template delegator for testNode() method.
|
void |
testNode(org.w3c.dom.Node aNode,
NodeTest forTest)
Validate a single Node by delegating to node type specific methods.
|
void |
testNotation(org.w3c.dom.Notation notation)
Template delegator for testNode() method.
|
void |
testProcessingInstruction(org.w3c.dom.ProcessingInstruction instr)
Template delegator for testNode() method.
|
void |
testText(org.w3c.dom.Text text)
Template delegator for testNode() method.
|
public void testNode(org.w3c.dom.Node aNode, NodeTest forTest) throws NodeTestException
testNode
in interface NodeTester
NodeTestException
- if the node fails the testtestAttribute(Attr)
,
testCDATASection(CDATASection)
,
testComment(Comment)
,
testDocumentType(DocumentType)
,
testElement(Element)
,
testEntity(Entity)
,
testEntityReference(EntityReference)
,
testNotation(Notation)
,
testProcessingInstruction(ProcessingInstruction)
,
testText(Text)
public void testAttribute(org.w3c.dom.Attr attribute) throws NodeTestException
attribute
- NodeTestException
- always: override if required in subclasspublic void testCDATASection(org.w3c.dom.CDATASection cdata) throws NodeTestException
cdata
- NodeTestException
- always: override if required in subclasspublic void testComment(org.w3c.dom.Comment comment) throws NodeTestException
comment
- NodeTestException
- always: override if required in subclasspublic void testDocumentType(org.w3c.dom.DocumentType doctype) throws NodeTestException
doctype
- NodeTestException
- always: override if required in subclasspublic void testElement(org.w3c.dom.Element element) throws NodeTestException
element
- NodeTestException
- always: override if required in subclasspublic void testEntity(org.w3c.dom.Entity entity) throws NodeTestException
entity
- NodeTestException
- always: override if required in subclasspublic void testEntityReference(org.w3c.dom.EntityReference reference) throws NodeTestException
reference
- NodeTestException
- always: override if required in subclasspublic void testNotation(org.w3c.dom.Notation notation) throws NodeTestException
notation
- NodeTestException
- always: override if required in subclasspublic void testProcessingInstruction(org.w3c.dom.ProcessingInstruction instr) throws NodeTestException
instr
- NodeTestException
- always: override if required in subclasspublic void testText(org.w3c.dom.Text text) throws NodeTestException
text
- NodeTestException
- always: override if required in subclasspublic void noMoreNodes(NodeTest forTest) throws NodeTestException
isValid
method were all the Nodes expected. By default do nothing:
can override to add custom logicnoMoreNodes
in interface NodeTester
NodeTestException
- if mode Nodes were expected