Class Evaluator.AttributeWithValueMatching

  • Enclosing class:
    Evaluator

    public static final class Evaluator.AttributeWithValueMatching
    extends Evaluator
    Evaluator for attribute name/value matching (value regex matching)
    • Field Detail

      • key

        java.lang.String key
      • pattern

        java.util.regex.Pattern pattern
    • Constructor Detail

      • AttributeWithValueMatching

        public AttributeWithValueMatching​(java.lang.String key,
                                          java.util.regex.Pattern pattern)
    • Method Detail

      • matches

        public boolean matches​(Element root,
                               Element element)
        Description copied from class: Evaluator
        Test if the element meets the evaluator's requirements.
        Specified by:
        matches in class Evaluator
        Parameters:
        root - Root of the matching subtree
        element - tested element
        Returns:
        Returns true if the requirements are met or false otherwise
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object