This is an automated email from the ASF dual-hosted git repository. markt-asf pushed a commit to branch 11.0.x in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit 098bf2b6101d21c998f080ac68a36e38aa01c4bd Author: Mark Thomas <[email protected]> AuthorDate: Thu May 7 15:46:33 2026 +0100 Remove unnecessary warning suppression after Javadoc updates --- java/org/apache/catalina/startup/FailedContext.java | 3 +-- .../webresources/AbstractSingleArchiveResourceSet.java | 3 +++ java/org/apache/jasper/compiler/ELNode.java | 3 --- java/org/apache/jasper/compiler/Node.java | 5 ++--- java/org/apache/naming/ServiceRef.java | 4 ++-- .../util/http/fileupload/impl/FileItemIteratorImpl.java | 4 ++-- .../java/org/apache/tomcat/jdbc/pool/DataSourceProxy.java | 14 ++++++++------ 7 files changed, 18 insertions(+), 18 deletions(-) diff --git a/java/org/apache/catalina/startup/FailedContext.java b/java/org/apache/catalina/startup/FailedContext.java index 68a32c9208..b7bb9badd8 100644 --- a/java/org/apache/catalina/startup/FailedContext.java +++ b/java/org/apache/catalina/startup/FailedContext.java @@ -1180,9 +1180,8 @@ public class FailedContext extends LifecycleMBeanBase implements Context { /** * Adds a valve to this context. This is a no-op for a failed context. * - * @param valve the valve to add + * @param valve the valve to add - ignored */ - @SuppressWarnings("unused") public synchronized void addValve(Valve valve) { // NO-OP } diff --git a/java/org/apache/catalina/webresources/AbstractSingleArchiveResourceSet.java b/java/org/apache/catalina/webresources/AbstractSingleArchiveResourceSet.java index 3902bc491c..9fa79f7ca1 100644 --- a/java/org/apache/catalina/webresources/AbstractSingleArchiveResourceSet.java +++ b/java/org/apache/catalina/webresources/AbstractSingleArchiveResourceSet.java @@ -50,6 +50,9 @@ public abstract class AbstractSingleArchiveResourceSet extends AbstractArchiveRe * @param webAppMount The web app mount * @param base The base * @param internalPath The internal path + * + * @throws IllegalArgumentException if the {@link WebResourceRoot} is available but this resource set cannot be + * started */ public AbstractSingleArchiveResourceSet(WebResourceRoot root, String webAppMount, String base, String internalPath) throws IllegalArgumentException { diff --git a/java/org/apache/jasper/compiler/ELNode.java b/java/org/apache/jasper/compiler/ELNode.java index 595d8e2286..a50f774b79 100644 --- a/java/org/apache/jasper/compiler/ELNode.java +++ b/java/org/apache/jasper/compiler/ELNode.java @@ -403,7 +403,6 @@ public abstract class ELNode { * * @throws JasperException if an error occurs during visitation */ - @SuppressWarnings("unused") public void visit(Function n) throws JasperException { // NOOP by default } @@ -415,7 +414,6 @@ public abstract class ELNode { * * @throws JasperException if an error occurs during visitation */ - @SuppressWarnings("unused") public void visit(Text n) throws JasperException { // NOOP by default } @@ -427,7 +425,6 @@ public abstract class ELNode { * * @throws JasperException if an error occurs during visitation */ - @SuppressWarnings("unused") public void visit(ELText n) throws JasperException { // NOOP by default } diff --git a/java/org/apache/jasper/compiler/Node.java b/java/org/apache/jasper/compiler/Node.java index 4be282373b..a58d586fe5 100644 --- a/java/org/apache/jasper/compiler/Node.java +++ b/java/org/apache/jasper/compiler/Node.java @@ -2844,13 +2844,12 @@ public abstract class Node implements TagConstants { } /** - * This method provides a place to put actions that are common to all nodes. Override this in the child visitor - * class if needed. + * This method provides a place to put actions that are common to all nodes. It is a NO-OP by default. Override + * this in the child visitor class if needed. * * @param n The node to visit * @throws JasperException if an error occurs while visiting the node */ - @SuppressWarnings("unused") protected void doVisit(Node n) throws JasperException { // NOOP by default } diff --git a/java/org/apache/naming/ServiceRef.java b/java/org/apache/naming/ServiceRef.java index 9280caab31..e72bfce544 100644 --- a/java/org/apache/naming/ServiceRef.java +++ b/java/org/apache/naming/ServiceRef.java @@ -102,7 +102,7 @@ public class ServiceRef extends AbstractRef { /** * Creates a ServiceRef with the given parameters and factory information. * - * @param refname the reference name + * @param refname the reference name - unused * @param serviceInterface the service interface class name * @param serviceQname the service QName (namespace and local part) * @param wsdl the WSDL location @@ -110,7 +110,7 @@ public class ServiceRef extends AbstractRef { * @param factory the factory class name * @param factoryLocation the factory location */ - public ServiceRef(@SuppressWarnings("unused") String refname, String serviceInterface, String[] serviceQname, + public ServiceRef(String refname, String serviceInterface, String[] serviceQname, String wsdl, String jaxrpcmapping, String factory, String factoryLocation) { super(serviceInterface, factory, factoryLocation); StringRefAddr refAddr; diff --git a/java/org/apache/tomcat/util/http/fileupload/impl/FileItemIteratorImpl.java b/java/org/apache/tomcat/util/http/fileupload/impl/FileItemIteratorImpl.java index 4682de2960..fd0b01a0b7 100644 --- a/java/org/apache/tomcat/util/http/fileupload/impl/FileItemIteratorImpl.java +++ b/java/org/apache/tomcat/util/http/fileupload/impl/FileItemIteratorImpl.java @@ -146,11 +146,11 @@ public class FileItemIteratorImpl implements FileItemIterator { * Initializes the multipart stream for processing the request. * * @param fileUploadBase The file upload base configuration - * @param pRequestContext The request context + * @param pRequestContext The request context - unused * @throws FileUploadException If the request content type is invalid or size exceeds limits * @throws IOException If an I/O error occurs */ - protected void init(final FileUploadBase fileUploadBase, @SuppressWarnings("unused") final RequestContext pRequestContext) + protected void init(final FileUploadBase fileUploadBase, final RequestContext pRequestContext) throws FileUploadException, IOException { final String contentType = ctx.getContentType(); if ((null == contentType) diff --git a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/DataSourceProxy.java b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/DataSourceProxy.java index d050dbf13a..fc8dc27be6 100644 --- a/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/DataSourceProxy.java +++ b/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/DataSourceProxy.java @@ -75,13 +75,14 @@ public class DataSourceProxy implements PoolConfiguration { /** * Check if this proxy wraps an instance of the given interface. - * This implementation always returns false. + * This implementation always returns {@code false}. + * <p> + * Has to match signature in DataSource. * - * @param iface The interface to check + * @param iface The interface to check - ignored * @return false * @throws SQLException never thrown */ - @SuppressWarnings("unused") // Has to match signature in DataSource public boolean isWrapperFor(Class<?> iface) throws SQLException { // we are not a wrapper of anything return false; @@ -90,14 +91,15 @@ public class DataSourceProxy implements PoolConfiguration { /** * Unwrap the proxy to the given interface. - * This implementation always returns null. + * This implementation always returns {@code null}. + * <p> + * Has to match signature in DataSource * * @param <T> The interface type - * @param iface The interface to unwrap to + * @param iface The interface to unwrap to - ignored * @return null * @throws SQLException never thrown */ - @SuppressWarnings("unused") // Has to match signature in DataSource public <T> T unwrap(Class<T> iface) throws SQLException { //we can't unwrap anything return null; --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
