Class ElementNameAndTextQualifier

    • Constructor Detail

      • ElementNameAndTextQualifier

        public ElementNameAndTextQualifier()
    • Method Detail

      • qualifyForComparison

        public boolean qualifyForComparison​(Element control,
                                            Element test)
        Determine whether two elements qualify for further Difference comparison.
        Specified by:
        qualifyForComparison in interface ElementQualifier
        Overrides:
        qualifyForComparison in class ElementNameQualifier
        Parameters:
        control - an Element from the control XML NodeList
        test - an Element from the test XML NodeList
        Returns:
        true if the two elements qualify for further comparison based on both the superclass qualification (namespace URI and non- namespaced tag name), and the qualification of the text nodes contained within the elements; false otherwise
      • similar

        protected boolean similar​(Text control,
                                  Text test)
        Determine whether the text nodes contain similar values
        Parameters:
        control - control text
        test - test text
        Returns:
        true if text nodes are similar, false otherwise
      • extractText

        protected Text extractText​(Element fromElement)
        Extract the normalized text from within an element
        Parameters:
        fromElement - element to extract text from
        Returns:
        extracted Text node (could be null)