code: public static boolean isMatch(final String regex, final CharSequence input) {
          return input != null && input.length() > 0 && Pattern.matches(regex, input);
      }
docs: Determines whether the regular is matched.
  
  @param regex regular expression
  @param input the string to match.
  @return {@code true}: matching<br>{@code false}: mismatching