Class CleanResults


  • public class CleanResults
    extends java.lang.Object
    This class contains the results of a scan. The list of error messages (errorMessages) will let the user know what, if any HTML errors existed, and what, if any, security or validation-related errors existed, and what was done about them.
    Author:
    Arshan Dabirsiaghi
    • Constructor Summary

      Constructors 
      Constructor Description
      CleanResults()  
      CleanResults​(long startOfScan, java.lang.String cleanHTML, org.w3c.dom.DocumentFragment XMLDocumentFragment, java.util.List<java.lang.String> errorMessages)  
      CleanResults​(long startOfScan, java.util.concurrent.Callable<java.lang.String> cleanHTML, org.w3c.dom.DocumentFragment XMLDocumentFragment, java.util.List<java.lang.String> errorMessages)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getCleanHTML()
      Return the filtered HTML as a String.
      org.w3c.dom.DocumentFragment getCleanXMLDocumentFragment()  
      java.util.List<java.lang.String> getErrorMessages()
      Return a list of error messages.
      int getNumberOfErrors()
      Return the number of errors encountered during filtering.
      double getScanTime()
      Return the time elapsed during the scan.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CleanResults

        public CleanResults()
      • CleanResults

        public CleanResults​(long startOfScan,
                            java.lang.String cleanHTML,
                            org.w3c.dom.DocumentFragment XMLDocumentFragment,
                            java.util.List<java.lang.String> errorMessages)
      • CleanResults

        public CleanResults​(long startOfScan,
                            java.util.concurrent.Callable<java.lang.String> cleanHTML,
                            org.w3c.dom.DocumentFragment XMLDocumentFragment,
                            java.util.List<java.lang.String> errorMessages)
    • Method Detail

      • getCleanXMLDocumentFragment

        public org.w3c.dom.DocumentFragment getCleanXMLDocumentFragment()
      • getCleanHTML

        public java.lang.String getCleanHTML()
        Return the filtered HTML as a String.
        Returns:
        A String object which contains the serialized, safe HTML.
      • getErrorMessages

        public java.util.List<java.lang.String> getErrorMessages()
        Return a list of error messages.
        Returns:
        An ArrayList object which contain the error messages after a scan.
      • getScanTime

        public double getScanTime()
        Return the time elapsed during the scan.
        Returns:
        A double primitive indicating the amount of time elapsed between the beginning and end of the scan in seconds.
      • getNumberOfErrors

        public int getNumberOfErrors()
        Return the number of errors encountered during filtering.