mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
Remove unneeded @NonNull annotations
See gh-28797
This commit is contained in:
@@ -21,7 +21,6 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
import org.jspecify.annotations.NonNull;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
import org.reactivestreams.Publisher;
|
||||
|
||||
@@ -379,7 +378,7 @@ public final class MultipartBodyBuilder {
|
||||
* Return the element type for the {@code Publisher} body.
|
||||
*/
|
||||
@Override
|
||||
public @NonNull ResolvableType getResolvableType() {
|
||||
public ResolvableType getResolvableType() {
|
||||
return this.resolvableType;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,7 +37,6 @@ import jakarta.xml.bind.Unmarshaller;
|
||||
import jakarta.xml.bind.annotation.XmlRootElement;
|
||||
import jakarta.xml.bind.annotation.XmlSeeAlso;
|
||||
import jakarta.xml.bind.annotation.XmlType;
|
||||
import org.jspecify.annotations.NonNull;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
import org.reactivestreams.Publisher;
|
||||
import reactor.core.Exceptions;
|
||||
@@ -172,7 +171,7 @@ public class Jaxb2XmlDecoder extends AbstractDecoder<Object> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NonNull Object decode(DataBuffer dataBuffer, ResolvableType targetType,
|
||||
public Object decode(DataBuffer dataBuffer, ResolvableType targetType,
|
||||
@Nullable MimeType mimeType, @Nullable Map<String, Object> hints) throws DecodingException {
|
||||
|
||||
try {
|
||||
|
||||
+2
-3
@@ -35,7 +35,6 @@ import jakarta.servlet.ServletInputStream;
|
||||
import jakarta.servlet.http.Cookie;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.jspecify.annotations.NonNull;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
import reactor.core.publisher.Flux;
|
||||
|
||||
@@ -214,12 +213,12 @@ class ServletServerHttpRequest extends AbstractServerHttpRequest {
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NonNull InetSocketAddress getLocalAddress() {
|
||||
public InetSocketAddress getLocalAddress() {
|
||||
return new InetSocketAddress(this.request.getLocalAddr(), this.request.getLocalPort());
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NonNull InetSocketAddress getRemoteAddress() {
|
||||
public InetSocketAddress getRemoteAddress() {
|
||||
return new InetSocketAddress(this.request.getRemoteHost(), this.request.getRemotePort());
|
||||
}
|
||||
|
||||
|
||||
+1
-2
@@ -29,7 +29,6 @@ import java.util.StringJoiner;
|
||||
import java.util.function.BiFunction;
|
||||
import java.util.function.UnaryOperator;
|
||||
|
||||
import org.jspecify.annotations.NonNull;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
|
||||
import org.springframework.util.Assert;
|
||||
@@ -196,7 +195,7 @@ final class HierarchicalUriComponents extends UriComponents {
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NonNull String getPath() {
|
||||
public String getPath() {
|
||||
return this.path.getPath();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user