Upgrade to Nullability Plugin 0.0.9

Closes gh-48638
This commit is contained in:
Andy Wilkinson
2026-01-08 11:59:51 +00:00
parent 9bd1a460a1
commit 0ffffee4bf
212 changed files with 2601 additions and 356 deletions
@@ -24,6 +24,8 @@ import java.util.Deque;
import java.util.List;
import java.util.concurrent.atomic.AtomicLong;
import org.jspecify.annotations.Nullable;
import org.springframework.http.HttpMethod;
import org.springframework.http.HttpStatus;
import org.springframework.http.MediaType;
@@ -105,11 +107,11 @@ public class MockClientHttpRequestFactory implements ClientHttpRequestFactory {
private final int delay;
private final byte[] payload;
private final byte @Nullable [] payload;
private final HttpStatus status;
Response(int delay, byte[] payload, HttpStatus status) {
Response(int delay, byte @Nullable [] payload, HttpStatus status) {
this.delay = delay;
this.payload = payload;
this.status = status;
@@ -0,0 +1,20 @@
/*
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@NullMarked
package org.springframework.boot.devtools.test;
import org.jspecify.annotations.NullMarked;
@@ -18,6 +18,8 @@ package org.springframework.boot.loader.launch;
import java.util.function.Consumer;
import org.jspecify.annotations.Nullable;
/**
* Fake launcher in the {@code org.springframework.boot.loader.launch} package used in
* {@code MainMethodTests}.
@@ -26,13 +28,15 @@ import java.util.function.Consumer;
*/
public final class FakeJarLauncher {
public static Consumer<String[]> action;
public static @Nullable Consumer<String[]> action;
private FakeJarLauncher() {
}
public static void main(String... args) {
action.accept(args);
if (action != null) {
action.accept(args);
}
}
}
@@ -0,0 +1,20 @@
/*
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@NullMarked
package org.springframework.boot.loader.launch;
import org.jspecify.annotations.NullMarked;