issrg.policytester
Class PTValidator

java.lang.Object
  extended by issrg.policytester.PTValidator
All Implemented Interfaces:
PolicyValidator

public class PTValidator
extends java.lang.Object
implements PolicyValidator

Author:
Chris

Constructor Summary
PTValidator()
          Creates a new instance of PTValidator
 
Method Summary
 void createDocument()
          Creates and sets a new valid and empty Document.
static java.lang.String[] getChildElements(org.w3c.dom.Node elem)
          Obtains the Child Elements of a Node.
 org.w3c.dom.Document getValidDocument()
          In case a new valid document is needed, create and make the document a valid one.
 void setDocument(org.w3c.dom.Document d)
          The Document to verify is set using this method.
 void validateDocument()
          Actual validation of the document goes here.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PTValidator

public PTValidator()
Creates a new instance of PTValidator

Method Detail

setDocument

public void setDocument(org.w3c.dom.Document d)
The Document to verify is set using this method.

Specified by:
setDocument in interface PolicyValidator
Parameters:
d - Document to be set.

validateDocument

public void validateDocument()
                      throws ValidationException
Description copied from interface: PolicyValidator
Actual validation of the document goes here.

Specified by:
validateDocument in interface PolicyValidator
Throws:
ValidationException

createDocument

public void createDocument()
Creates and sets a new valid and empty Document.


getValidDocument

public org.w3c.dom.Document getValidDocument()
Description copied from interface: PolicyValidator
In case a new valid document is needed, create and make the document a valid one.

Specified by:
getValidDocument in interface PolicyValidator

getChildElements

public static java.lang.String[] getChildElements(org.w3c.dom.Node elem)
Obtains the Child Elements of a Node. Can be deprecated or improved.

Parameters:
elem - the Node Element to obtain the Child Elements of
Returns:
String[] An String Array of Child Elements