diff --git a/cli/src/main/java/hudson/util/QuotedStringTokenizer.java b/cli/src/main/java/hudson/util/QuotedStringTokenizer.java index 017016d7d8..b81de9194d 100644 --- a/cli/src/main/java/hudson/util/QuotedStringTokenizer.java +++ b/cli/src/main/java/hudson/util/QuotedStringTokenizer.java @@ -472,7 +472,7 @@ public class QuotedStringTokenizer (convertHexDigit((byte)s.charAt(i++))<<24)+ (convertHexDigit((byte)s.charAt(i++))<<16)+ (convertHexDigit((byte)s.charAt(i++))<<8)+ - (convertHexDigit((byte)s.charAt(i++))) + convertHexDigit((byte)s.charAt(i++)) ) ); break; diff --git a/core/src/main/java/hudson/ExtensionList.java b/core/src/main/java/hudson/ExtensionList.java index 9855ec9e1e..05eeaa872d 100644 --- a/core/src/main/java/hudson/ExtensionList.java +++ b/core/src/main/java/hudson/ExtensionList.java @@ -246,7 +246,7 @@ public class ExtensionList extends AbstractList implements OnMaster { return removed; } - private boolean removeComponent(Collection> collection, Object t) { + private boolean removeComponent(Collection> collection, Object t) { for (ExtensionComponent c : collection) { if (c.getInstance().equals(t)) { return collection.remove(c); diff --git a/core/src/main/java/hudson/ExtensionListView.java b/core/src/main/java/hudson/ExtensionListView.java index 53a577522a..c361c1a620 100644 --- a/core/src/main/java/hudson/ExtensionListView.java +++ b/core/src/main/java/hudson/ExtensionListView.java @@ -144,7 +144,7 @@ public class ExtensionListView { } @Override - public T[] toArray(T[] array) { + public X[] toArray(X[] array) { return storage().toArray(array); } diff --git a/core/src/main/java/hudson/FilePath.java b/core/src/main/java/hudson/FilePath.java index ff868a31c5..f4ded0b0cd 100644 --- a/core/src/main/java/hudson/FilePath.java +++ b/core/src/main/java/hudson/FilePath.java @@ -2023,6 +2023,7 @@ public final class FilePath implements SerializableOnlyOverRemoting { * List up files in this directory that matches the given Ant-style filter. * * @param includes + * See {@link FileSet} for the syntax. String like "foo/*.zip" or "foo/**/*.xml" * @param excludes * See {@link FileSet} for the syntax. String like "foo/*.zip" or "foo/**/*.xml" * @return @@ -2038,6 +2039,7 @@ public final class FilePath implements SerializableOnlyOverRemoting { * List up files in this directory that matches the given Ant-style filter. * * @param includes + * See {@link FileSet} for the syntax. String like "foo/*.zip" or "foo/**/*.xml" * @param excludes * See {@link FileSet} for the syntax. String like "foo/*.zip" or "foo/**/*.xml" * @param defaultExcludes whether to use the ant default excludes diff --git a/core/src/main/java/hudson/Functions.java b/core/src/main/java/hudson/Functions.java index 96200deb4f..6756715726 100644 --- a/core/src/main/java/hudson/Functions.java +++ b/core/src/main/java/hudson/Functions.java @@ -236,8 +236,6 @@ public class Functions { /** * Returns a localized string for the specified date, not including time. - * @param date - * @return */ @Restricted(NoExternalUse.class) public static String localDate(Date date) { @@ -250,9 +248,6 @@ public class Functions { /** * Returns a human-readable string describing the time difference between now and the specified date. - * - * @param date - * @return */ @Restricted(NoExternalUse.class) public static String getTimeSpanString(Date date) { diff --git a/core/src/main/java/hudson/PluginStrategy.java b/core/src/main/java/hudson/PluginStrategy.java index 0a4a6e7968..9645d9c780 100644 --- a/core/src/main/java/hudson/PluginStrategy.java +++ b/core/src/main/java/hudson/PluginStrategy.java @@ -70,8 +70,6 @@ public interface PluginStrategy extends ExtensionPoint { /** * Optionally start services provided by the plugin. Should be called * when all plugins are loaded. - * - * @param plugin */ void initializeComponents(PluginWrapper plugin); diff --git a/core/src/main/java/hudson/PluginWrapper.java b/core/src/main/java/hudson/PluginWrapper.java index 8afe949c97..0fee6b1ea2 100644 --- a/core/src/main/java/hudson/PluginWrapper.java +++ b/core/src/main/java/hudson/PluginWrapper.java @@ -721,7 +721,6 @@ public class PluginWrapper implements Comparable, ModelObject { /** * Disable a plugin wihout checking any dependency. Only add the disable file. - * @throws IOException */ private void disableWithoutCheck() throws IOException { try (OutputStream os = Files.newOutputStream(disableFile.toPath())) { diff --git a/core/src/main/java/hudson/ProxyConfiguration.java b/core/src/main/java/hudson/ProxyConfiguration.java index d04fad9ecb..3a48c857da 100644 --- a/core/src/main/java/hudson/ProxyConfiguration.java +++ b/core/src/main/java/hudson/ProxyConfiguration.java @@ -344,7 +344,6 @@ public final class ProxyConfiguration extends AbstractDescribableImpl,R extends A public DirectoryBrowserSupport doWs( StaplerRequest req, StaplerResponse rsp ) throws IOException, ServletException, InterruptedException { checkPermission(Item.WORKSPACE); FilePath ws = getSomeWorkspace(); - if ((ws == null) || (!ws.exists())) { + if ((ws == null) || !ws.exists()) { // if there's no workspace, report a nice error message // Would be good if when asked for *plain*, do something else! // (E.g. return 404, or send empty doc.) diff --git a/core/src/main/java/hudson/model/Actionable.java b/core/src/main/java/hudson/model/Actionable.java index a986a5ab21..dbe8a80c40 100644 --- a/core/src/main/java/hudson/model/Actionable.java +++ b/core/src/main/java/hudson/model/Actionable.java @@ -319,7 +319,6 @@ public abstract class Actionable extends AbstractModelObject implements ModelObj /** * Gets the action (first instance to be found) of a specified type that contributed to this build. * - * @param type * @return The action or {@code null} if no such actions exist. * @see #getActions(Class) */ diff --git a/core/src/main/java/hudson/model/Computer.java b/core/src/main/java/hudson/model/Computer.java index 0fa8f91a76..817c3460be 100644 --- a/core/src/main/java/hudson/model/Computer.java +++ b/core/src/main/java/hudson/model/Computer.java @@ -1506,7 +1506,7 @@ public /*transient*/ abstract class Computer extends Actionable implements Acces throw new ServletException("No such node " + nodeName); } - if ((!proposedName.equals(nodeName)) + if (!proposedName.equals(nodeName) && Jenkins.get().getNode(proposedName) != null) { throw new FormException(Messages.ComputerSet_SlaveAlreadyExists(proposedName), "name"); } diff --git a/core/src/main/java/hudson/model/Descriptor.java b/core/src/main/java/hudson/model/Descriptor.java index c699bff536..8ccbf90a52 100644 --- a/core/src/main/java/hudson/model/Descriptor.java +++ b/core/src/main/java/hudson/model/Descriptor.java @@ -625,7 +625,7 @@ public abstract class Descriptor> implements Saveable, private static class NewInstanceBindInterceptor extends BindInterceptor { private final BindInterceptor oldInterceptor; - private final Map processed = new IdentityHashMap<>(); + private final IdentityHashMap processed = new IdentityHashMap<>(); NewInstanceBindInterceptor(BindInterceptor oldInterceptor) { LOGGER.log(Level.FINER, "new interceptor delegating to {0}", oldInterceptor); diff --git a/core/src/main/java/hudson/model/FileParameterValue.java b/core/src/main/java/hudson/model/FileParameterValue.java index 35d7a21639..562116328c 100644 --- a/core/src/main/java/hudson/model/FileParameterValue.java +++ b/core/src/main/java/hudson/model/FileParameterValue.java @@ -229,9 +229,6 @@ public class FileParameterValue extends ParameterValue { /** * Serve this file parameter in response to a {@link StaplerRequest}. - * - * @param request - * @param response */ public DirectoryBrowserSupport doDynamic(StaplerRequest request, StaplerResponse response) { AbstractBuild build = (AbstractBuild)request.findAncestor(AbstractBuild.class).getObject(); diff --git a/core/src/main/java/hudson/model/Fingerprint.java b/core/src/main/java/hudson/model/Fingerprint.java index 1a58caf458..a4809e5260 100644 --- a/core/src/main/java/hudson/model/Fingerprint.java +++ b/core/src/main/java/hudson/model/Fingerprint.java @@ -824,7 +824,7 @@ public class Fingerprint implements ModelObject, Saveable { 1479 */ - return new RangeSet((List)(collectionConv.unmarshal(reader,context))); + return new RangeSet((List)collectionConv.unmarshal(reader,context)); } else { return RangeSet.fromString(reader.getValue(),true); } diff --git a/core/src/main/java/hudson/model/ListView.java b/core/src/main/java/hudson/model/ListView.java index 53ab1e44df..8d95f93dde 100644 --- a/core/src/main/java/hudson/model/ListView.java +++ b/core/src/main/java/hudson/model/ListView.java @@ -494,7 +494,6 @@ public class ListView extends View implements DirectlyModifiableView { /** * Deprecated see, {@link StatusFilter} - * @param statusFilter */ @Deprecated @DataBoundSetter diff --git a/core/src/main/java/hudson/model/Node.java b/core/src/main/java/hudson/model/Node.java index 15d8099d24..47c44af19b 100644 --- a/core/src/main/java/hudson/model/Node.java +++ b/core/src/main/java/hudson/model/Node.java @@ -309,7 +309,6 @@ public abstract class Node extends AbstractModelObject implements Reconfigurable * Return all the labels assigned dynamically to this node. * This calls all the LabelFinder implementations with the node converts * the results into Labels. - * @return HashSet