in apache-rat-core/src/main/java/org/apache/rat/config/parameters/Description.java [247:262]
public Method setter(final Class<?> clazz) throws NoSuchMethodException, SecurityException {
String methodName = methodName(isCollection ? "add" : "set");
switch (type) {
case LICENSE:
throw new NoSuchMethodException("Can not set a License as a child");
case MATCHER:
return clazz.getMethod(methodName, IHeaderMatcher.Builder.class);
case PARAMETER:
return clazz.getMethod(methodName,
IHeaderMatcher.class.isAssignableFrom(childClass) ? IHeaderMatcher.Builder.class : childClass);
case BUILD_PARAMETER:
return clazz.getMethod(methodName, childClass);
}
// should not happen
throw new IllegalStateException("Type " + type + " not valid.");
}