Fail Gradle build for Javadoc warnings
In order to catch Javadoc errors in the build, we now enable the `Xwerror` flag for the `javadoc` tool. In addition, we now use `Xdoclint:syntax` instead of `Xdoclint:none` in order to validate syntax within our Javadoc. This commit fixes all resulting Javadoc errors and warnings. This commit also upgrades to Undertow 2.2.12.Final and fixes the artifact names for exclusions for the Servlet and annotations APIs. The incorrect exclusion of the Servlet API resulted in the Servlet API being on the classpath twice for the javadoc task, which resulted in the following warnings in previous builds. javadoc: warning - Multiple sources of package comments found for package "javax.servlet" javadoc: warning - Multiple sources of package comments found for package "javax.servlet.http" javadoc: warning - Multiple sources of package comments found for package "javax.servlet.descriptor" javadoc: warning - Multiple sources of package comments found for package "javax.servlet.annotation" Closes gh-27480
This commit is contained in:
@@ -310,10 +310,10 @@ public class Constants {
|
||||
* Convert the given bean property name to a constant name prefix.
|
||||
* <p>Uses a common naming idiom: turning all lower case characters to
|
||||
* upper case, and prepending upper case characters with an underscore.
|
||||
* <p>Example: "imageSize" -> "IMAGE_SIZE"<br>
|
||||
* Example: "imagesize" -> "IMAGESIZE".<br>
|
||||
* Example: "ImageSize" -> "_IMAGE_SIZE".<br>
|
||||
* Example: "IMAGESIZE" -> "_I_M_A_G_E_S_I_Z_E"
|
||||
* <p>Example: "imageSize" → "IMAGE_SIZE"<br>
|
||||
* Example: "imagesize" → "IMAGESIZE".<br>
|
||||
* Example: "ImageSize" → "_IMAGE_SIZE".<br>
|
||||
* Example: "IMAGESIZE" → "_I_M_A_G_E_S_I_Z_E"
|
||||
* @param propertyName the name of the bean property
|
||||
* @return the corresponding constant name prefix
|
||||
* @see #getValuesForProperty
|
||||
|
||||
@@ -91,7 +91,6 @@ public interface SmartClassLoader {
|
||||
* not being possible (thrown by the default implementation in this interface)
|
||||
* @since 5.3.4
|
||||
* @see ClassLoader#defineClass(String, byte[], int, int, ProtectionDomain)
|
||||
* @see java.lang.invoke.MethodHandles.Lookup#defineClass(byte[])
|
||||
*/
|
||||
default Class<?> publicDefineClass(String name, byte[] b, @Nullable ProtectionDomain protectionDomain) {
|
||||
throw new UnsupportedOperationException();
|
||||
|
||||
@@ -70,9 +70,9 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||
* <p>Note: When building relative resources via {@link #createRelative},
|
||||
* it makes a difference whether the specified resource base path here
|
||||
* ends with a slash or not. In the case of "C:/dir1/", relative paths
|
||||
* will be built underneath that root: e.g. relative path "dir2" ->
|
||||
* will be built underneath that root: e.g. relative path "dir2" →
|
||||
* "C:/dir1/dir2". In the case of "C:/dir1", relative paths will apply
|
||||
* at the same directory level: relative path "dir2" -> "C:/dir2".
|
||||
* at the same directory level: relative path "dir2" → "C:/dir2".
|
||||
* @param path a file path
|
||||
* @see #FileSystemResource(Path)
|
||||
*/
|
||||
@@ -87,7 +87,7 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||
* Create a new {@code FileSystemResource} from a {@link File} handle.
|
||||
* <p>Note: When building relative resources via {@link #createRelative},
|
||||
* the relative path will apply <i>at the same directory level</i>:
|
||||
* e.g. new File("C:/dir1"), relative path "dir2" -> "C:/dir2"!
|
||||
* e.g. new File("C:/dir1"), relative path "dir2" → "C:/dir2"!
|
||||
* If you prefer to have relative paths built underneath the given root directory,
|
||||
* use the {@link #FileSystemResource(String) constructor with a file path}
|
||||
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
||||
@@ -111,7 +111,7 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||
* path cleaning and {@link #createRelative(String)} handling.
|
||||
* <p>Note: When building relative resources via {@link #createRelative},
|
||||
* the relative path will apply <i>at the same directory level</i>:
|
||||
* e.g. Paths.get("C:/dir1"), relative path "dir2" -> "C:/dir2"!
|
||||
* e.g. Paths.get("C:/dir1"), relative path "dir2" → "C:/dir2"!
|
||||
* If you prefer to have relative paths built underneath the given root directory,
|
||||
* use the {@link #FileSystemResource(String) constructor with a file path}
|
||||
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
||||
|
||||
@@ -64,7 +64,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||
* Create a new PathResource from a Path handle.
|
||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||
* @param path a Path handle
|
||||
*/
|
||||
public PathResource(Path path) {
|
||||
@@ -76,7 +76,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||
* Create a new PathResource from a Path handle.
|
||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||
* @param path a path
|
||||
* @see java.nio.file.Paths#get(String, String...)
|
||||
*/
|
||||
@@ -89,7 +89,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||
* Create a new PathResource from a Path handle.
|
||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||
* @param uri a path URI
|
||||
* @see java.nio.file.Paths#get(URI)
|
||||
*/
|
||||
|
||||
@@ -475,14 +475,14 @@ public class AntPathMatcher implements PathMatcher {
|
||||
|
||||
/**
|
||||
* Given a pattern and a full path, determine the pattern-mapped part. <p>For example: <ul>
|
||||
* <li>'{@code /docs/cvs/commit.html}' and '{@code /docs/cvs/commit.html} -> ''</li>
|
||||
* <li>'{@code /docs/*}' and '{@code /docs/cvs/commit} -> '{@code cvs/commit}'</li>
|
||||
* <li>'{@code /docs/cvs/*.html}' and '{@code /docs/cvs/commit.html} -> '{@code commit.html}'</li>
|
||||
* <li>'{@code /docs/**}' and '{@code /docs/cvs/commit} -> '{@code cvs/commit}'</li>
|
||||
* <li>'{@code /docs/**\/*.html}' and '{@code /docs/cvs/commit.html} -> '{@code cvs/commit.html}'</li>
|
||||
* <li>'{@code /*.html}' and '{@code /docs/cvs/commit.html} -> '{@code docs/cvs/commit.html}'</li>
|
||||
* <li>'{@code *.html}' and '{@code /docs/cvs/commit.html} -> '{@code /docs/cvs/commit.html}'</li>
|
||||
* <li>'{@code *}' and '{@code /docs/cvs/commit.html} -> '{@code /docs/cvs/commit.html}'</li> </ul>
|
||||
* <li>'{@code /docs/cvs/commit.html}' and '{@code /docs/cvs/commit.html} → ''</li>
|
||||
* <li>'{@code /docs/*}' and '{@code /docs/cvs/commit} → '{@code cvs/commit}'</li>
|
||||
* <li>'{@code /docs/cvs/*.html}' and '{@code /docs/cvs/commit.html} → '{@code commit.html}'</li>
|
||||
* <li>'{@code /docs/**}' and '{@code /docs/cvs/commit} → '{@code cvs/commit}'</li>
|
||||
* <li>'{@code /docs/**\/*.html}' and '{@code /docs/cvs/commit.html} → '{@code cvs/commit.html}'</li>
|
||||
* <li>'{@code /*.html}' and '{@code /docs/cvs/commit.html} → '{@code docs/cvs/commit.html}'</li>
|
||||
* <li>'{@code *.html}' and '{@code /docs/cvs/commit.html} → '{@code /docs/cvs/commit.html}'</li>
|
||||
* <li>'{@code *}' and '{@code /docs/cvs/commit.html} → '{@code /docs/cvs/commit.html}'</li> </ul>
|
||||
* <p>Assumes that {@link #match} returns {@code true} for '{@code pattern}' and '{@code path}', but
|
||||
* does <strong>not</strong> enforce this.
|
||||
*/
|
||||
|
||||
@@ -43,7 +43,7 @@ import org.springframework.lang.Nullable;
|
||||
*
|
||||
* <pre class="code">
|
||||
* Assert.notNull(clazz, "The class must not be null");
|
||||
* Assert.isTrue(i > 0, "The value must be greater than zero");</pre>
|
||||
* Assert.isTrue(i > 0, "The value must be greater than zero");</pre>
|
||||
*
|
||||
* <p>Mainly for internal use within the framework; for a more comprehensive suite
|
||||
* of assertion utilities consider {@code org.apache.commons.lang3.Validate} from
|
||||
|
||||
@@ -288,7 +288,7 @@ public class MethodInvoker {
|
||||
* Algorithm that judges the match between the declared parameter types of a candidate method
|
||||
* and a specific list of arguments that this method is supposed to be invoked with.
|
||||
* <p>Determines a weight that represents the class hierarchy difference between types and
|
||||
* arguments. A direct match, i.e. type Integer -> arg of class Integer, does not increase
|
||||
* arguments. A direct match, i.e. type Integer → arg of class Integer, does not increase
|
||||
* the result - all direct matches means weight 0. A match between type Object and arg of
|
||||
* class Integer would increase the weight by 2, due to the superclass 2 steps up in the
|
||||
* hierarchy (i.e. Object) being the last one that still matches the required type Object.
|
||||
|
||||
@@ -94,7 +94,7 @@ public interface PathMatcher {
|
||||
* Given a pattern and a full path, extract the URI template variables. URI template
|
||||
* variables are expressed through curly brackets ('{' and '}').
|
||||
* <p>For example: For pattern "/hotels/{hotel}" and path "/hotels/1", this method will
|
||||
* return a map containing "hotel"->"1".
|
||||
* return a map containing "hotel" → "1".
|
||||
* @param pattern the path pattern, possibly containing URI templates
|
||||
* @param path the full path to extract template variables from
|
||||
* @return a map, containing variable names as keys; variables values as values
|
||||
|
||||
@@ -571,7 +571,7 @@ public abstract class StringUtils {
|
||||
|
||||
/**
|
||||
* Extract the filename from the given Java resource path,
|
||||
* e.g. {@code "mypath/myfile.txt" -> "myfile.txt"}.
|
||||
* e.g. {@code "mypath/myfile.txt" → "myfile.txt"}.
|
||||
* @param path the file path (may be {@code null})
|
||||
* @return the extracted filename, or {@code null} if none
|
||||
*/
|
||||
@@ -587,7 +587,7 @@ public abstract class StringUtils {
|
||||
|
||||
/**
|
||||
* Extract the filename extension from the given Java resource path,
|
||||
* e.g. "mypath/myfile.txt" -> "txt".
|
||||
* e.g. "mypath/myfile.txt" → "txt".
|
||||
* @param path the file path (may be {@code null})
|
||||
* @return the extracted filename extension, or {@code null} if none
|
||||
*/
|
||||
@@ -612,7 +612,7 @@ public abstract class StringUtils {
|
||||
|
||||
/**
|
||||
* Strip the filename extension from the given Java resource path,
|
||||
* e.g. "mypath/myfile.txt" -> "mypath/myfile".
|
||||
* e.g. "mypath/myfile.txt" → "mypath/myfile".
|
||||
* @param path the file path
|
||||
* @return the path with stripped filename extension
|
||||
*/
|
||||
|
||||
@@ -81,8 +81,8 @@ public class InvertibleComparator<T> implements Comparator<T>, Serializable {
|
||||
}
|
||||
|
||||
/**
|
||||
* Invert the sort order: ascending -> descending or
|
||||
* descending -> ascending.
|
||||
* Invert the sort order: ascending → descending or
|
||||
* descending → ascending.
|
||||
*/
|
||||
public void invertOrder() {
|
||||
this.ascending = !this.ascending;
|
||||
|
||||
Reference in New Issue
Block a user