private static RegexRule getRuleFromMatcher(Collection<RegexRule> rules, Matcher matcher) {
		return rules.stream()
				.filter(rule -> matcher.group(rule.name()) != null)
				.findFirst()
				.orElse(null);
	}
@param rules
		Rules to search for.
@param matcher
		Matcher to pull rule name from using matched group's name.

@return Rule with matching name as matched group.
recaf-ui/src/main/java/software/coley/recaf/ui/control/richtext/syntax/RegexSyntaxHighlighter.java