ottlinger commented on code in PR #233:
URL: https://github.com/apache/creadur-rat/pull/233#discussion_r1564204184
##########
apache-rat-core/src/main/java/org/apache/rat/configuration/builders/MatcherRefBuilder.java:
##########
@@ -56,31 +68,53 @@ public MatcherRefBuilder setMatchers(Map<String,
IHeaderMatcher> matchers) {
@Override
public IHeaderMatcher build() {
+ if (matchers == null) {
+ throw new ConfigurationException("'matchers' not set");
+ }
IHeaderMatcher result = matchers.get(referenceId);
return result != null ? result : new IHeaderMatcherProxy(referenceId,
matchers);
}
@Override
public String toString() {
- return "MathcerRefBuilder: "+referenceId;
+ return "MathcerRefBuilder: " + referenceId;
}
-
+
/**
- * A class that is a proxy to the actual matcher. It retrieves the actual
matcher from the map of
- * matcher ids to matcher instances one the first use of the matcher.
This allows earlier read matchers
- * to reference later constructed matchers as long as all the matchers are
constructed before the earlier one is
- * used.
+ * A class that is a proxy to the actual matcher. It retrieves the actual
+ * matcher from the map of matcher ids to matcher instances one the first
use of
Review Comment:
on the first use of .....
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]