Skip to content

Commit 256dee6

Browse files
committed
Merge pull request #19978 from dreis2211
* pr/19978: Update copyright year of changed files Polish buildSrc Closes gh-19978
2 parents bed8ff6 + e9339be commit 256dee6

File tree

9 files changed

+15
-13
lines changed

9 files changed

+15
-13
lines changed

Diff for: buildSrc/src/main/java/org/springframework/boot/build/bom/BomExtension.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public class BomExtension {
5050

5151
private final Map<String, String> artifactVersionProperties = new HashMap<>();
5252

53-
private final List<Library> libraries = new ArrayList<Library>();
53+
private final List<Library> libraries = new ArrayList<>();
5454

5555
private final UpgradeHandler upgradeHandler = new UpgradeHandler();
5656

Diff for: buildSrc/src/main/java/org/springframework/boot/build/bom/CheckBom.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ private void checkExclusions(String groupId, Module module, DependencyVersion ve
7171
for (String exclusion : exclusions) {
7272
if (!resolved.contains(exclusion) && exclusion.endsWith(":*")) {
7373
String group = exclusion.substring(0, exclusion.indexOf(':') + 1);
74-
if (!resolved.stream().filter((candidate) -> candidate.startsWith(group)).findFirst().isPresent()) {
74+
if (resolved.stream().noneMatch((candidate) -> candidate.startsWith(group))) {
7575
unused.add(exclusion);
7676
}
7777
}

Diff for: buildSrc/src/main/java/org/springframework/boot/build/bom/bomr/MavenMetadataVersionResolver.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,15 +62,15 @@ final class MavenMetadataVersionResolver implements VersionResolver {
6262

6363
@Override
6464
public SortedSet<DependencyVersion> resolveVersions(String groupId, String artifactId) {
65-
Set<String> versions = new HashSet<String>();
65+
Set<String> versions = new HashSet<>();
6666
for (String repositoryUrl : this.repositoryUrls) {
6767
versions.addAll(resolveVersions(groupId, artifactId, repositoryUrl));
6868
}
6969
return new TreeSet<>(versions.stream().map(DependencyVersion::parse).collect(Collectors.toSet()));
7070
}
7171

7272
private Set<String> resolveVersions(String groupId, String artifactId, String repositoryUrl) {
73-
Set<String> versions = new HashSet<String>();
73+
Set<String> versions = new HashSet<>();
7474
String url = repositoryUrl + "/" + groupId.replace('.', '/') + "/" + artifactId + "/maven-metadata.xml";
7575
try {
7676
String metadata = this.rest.getForObject(url, String.class);

Diff for: buildSrc/src/main/java/org/springframework/boot/build/cli/HomebrewFormula.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,11 @@
1818

1919
import java.util.Collections;
2020

21+
import org.gradle.api.Task;
2122
import org.gradle.api.tasks.TaskAction;
2223

2324
/**
24-
* A {@Task} for creating a Homebrew formula manifest.
25+
* A {@link Task} for creating a Homebrew formula manifest.
2526
*
2627
* @author Andy Wilkinson
2728
*/

Diff for: buildSrc/src/main/java/org/springframework/boot/build/cli/ScoopManifest.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,11 @@
1818

1919
import java.util.Collections;
2020

21+
import org.gradle.api.Task;
2122
import org.gradle.api.tasks.TaskAction;
2223

2324
/**
24-
* A {@Task} for creating a Scoop manifest.
25+
* A {@link Task} for creating a Scoop manifest.
2526
*
2627
* @author Andy Wilkinson
2728
*/

Diff for: buildSrc/src/main/java/org/springframework/boot/build/constraints/ExtractVersionConstraints.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2019-2020 the original author or authors.
2+
* Copyright 2012-2020 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -55,7 +55,7 @@ public class ExtractVersionConstraints extends AbstractTask {
5555

5656
private final Set<VersionProperty> versionProperties = new TreeSet<>();
5757

58-
private final List<String> projectPaths = new ArrayList<String>();
58+
private final List<String> projectPaths = new ArrayList<>();
5959

6060
public ExtractVersionConstraints() {
6161
DependencyHandler dependencies = getProject().getDependencies();

Diff for: buildSrc/src/main/java/org/springframework/boot/build/log4j2/ReproducibleLog4j2PluginsDatAction.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
import org.gradle.api.tasks.compile.JavaCompile;
3333

3434
/**
35-
* An {@Action} to post-process a {@code Log4j2Plugins.dat} and re-order its content so
36-
* that it is reproducible.
35+
* An {@link Action} to post-process a {@code Log4j2Plugins.dat} and re-order its content
36+
* so that it is reproducible.
3737
*
3838
* @author Andy Wilkinson
3939
*/

Diff for: buildSrc/src/main/java/org/springframework/boot/build/mavenplugin/PluginXmlParser.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2019-2020 the original author or authors.
2+
* Copyright 2012-2020 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -63,7 +63,7 @@ private String textAt(String path, Node source) throws XPathExpressionException
6363
}
6464

6565
private List<Mojo> parseMojos(Node plugin) throws XPathExpressionException {
66-
List<Mojo> mojos = new ArrayList<Mojo>();
66+
List<Mojo> mojos = new ArrayList<>();
6767
for (Node mojoNode : nodesAt("//plugin/mojos/mojo", plugin)) {
6868
mojos.add(new Mojo(textAt("goal", mojoNode), format(textAt("description", mojoNode)),
6969
parseParameters(mojoNode)));

Diff for: buildSrc/src/main/java/org/springframework/boot/build/test/IntegrationTestPlugin.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
import org.gradle.plugins.ide.eclipse.model.EclipseModel;
2929

3030
/**
31-
* A {@Plugin} to configure integration testing support in a {@link Project}.
31+
* A {@link Plugin} to configure integration testing support in a {@link Project}.
3232
*
3333
* @author Andy Wilkinson
3434
*/

0 commit comments

Comments
 (0)