Class StringMatcher

    • Field Detail

      • value

        private final java.lang.String value
        The text value to match against.
      • mode

        private final StringMatcher.Mode mode
        The mode to apply for matching the given value against the matcher's input.
    • Constructor Detail

      • StringMatcher

        public StringMatcher​(java.lang.String value,
                             StringMatcher.Mode mode)
        Creates a new string matcher.
        Parameters:
        value - The value that is the base of the matching.
        mode - The mode to apply for matching the given value against the matcher's input
    • Method Detail

      • matches

        public boolean matches​(java.lang.String target)
        Matches a target against this element matcher.
        Parameters:
        target - The instance to be matched.
        Returns:
        true if the given element is matched by this matcher or false otherwise.
      • toString

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