ascheman commented on code in PR #11505:
URL: https://github.com/apache/maven/pull/11505#discussion_r2616891087
##########
impl/maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilder.java:
##########
@@ -1099,6 +1123,190 @@ public Set<Entry<K, V>> entrySet() {
}
}
+ /**
+ * Context object for resource handling configuration.
+ * Groups parameters shared between main and test resource handling to
reduce method parameter count.
+ */
+ private record ResourceHandlingContext(
+ MavenProject project,
+ Path baseDir,
+ Set<String> modules,
+ boolean modularProject,
+ ModelBuilderResult result) {}
+
+ /**
+ * Handles resource configuration for a given scope (main or test).
+ * This method applies the resource priority rules:
+ * <ol>
+ * <li>Modular project: use resources from <sources> if present,
otherwise inject defaults</li>
Review Comment:
> > This is a private method so the javadoc won't appear in HTML.
>
> Well, depending which `-Xdoclint` options are enabled (if any), removing
the escapes could cause a compilation warning of failure. Rather than removing
the escapes, I suggest to use `{@code}`, which automatically does the escapes.
Example:
>
> ```
> <li>Modular project: use resources from {@code <sources>} if present
(etc...)
> ```
Changed this in 7bbd727c2f9536fba794346e43c8b872dbee2518 by now (will try to
follow this approach in the future).
Perhaps I have to squash some commits (or the overall change) before
merging. Will leave it in place for some days to enable further review.
--
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]