Spring cleaning: add missing @⁠Override annotations

This commit is contained in:
Sam Brannen
2024-02-23 11:55:06 +01:00
parent d0ffc16efc
commit c98bebd6d3
8 changed files with 10 additions and 0 deletions

View File

@@ -395,6 +395,7 @@ public interface Errors {
* e.g. for inclusion in an exception message.
* @see #failOnError(Function)
*/
@Override
String toString();
}

View File

@@ -625,6 +625,7 @@ class ClassUtilsTests {
}
@Override
public void packageAccessiblePrint() {
}

View File

@@ -204,6 +204,7 @@ class BeanPropertyRowMapperTests extends AbstractRowMapperTests {
private static class CustomPerson extends Person {
@Override
@MyColumnName("birthdate")
public void setBirth_date(Date date) {
super.setBirth_date(date);

View File

@@ -127,10 +127,12 @@ class RSocketServiceIntegrationTests {
@Controller
static class ServerController implements Service {
@Override
public Mono<String> echoAsync(String payload) {
return Mono.delay(Duration.ofMillis(10)).map(aLong -> payload + " async");
}
@Override
public Flux<String> echoStream(String payload) {
return Flux.interval(Duration.ofMillis(10)).map(aLong -> payload + " " + aLong);
}

View File

@@ -546,6 +546,7 @@ public class SimpAnnotationMethodMessageHandlerTests {
Map<String, Object> arguments = new LinkedHashMap<>();
@Override
@MessageMapping("/binding/id/{id}")
public void simpleBinding(Long id) {
this.method = "simpleBinding";

View File

@@ -85,6 +85,7 @@ public final class ReactiveHttpRequestValues extends HttpRequestValues {
* <p>This is mutually exclusive with {@link #getBodyValue()}.
* Only one of the two or neither is set.
*/
@Override
@SuppressWarnings("removal")
@Nullable
public Publisher<?> getBody() {
@@ -94,6 +95,7 @@ public final class ReactiveHttpRequestValues extends HttpRequestValues {
/**
* Return the element type for a {@linkplain #getBodyPublisher() body publisher}.
*/
@Override
@SuppressWarnings("removal")
@Nullable
public ParameterizedTypeReference<?> getBodyElementType() {

View File

@@ -500,6 +500,7 @@ public class UriComponentsBuilder implements UriBuilder, Cloneable {
* @since 4.1
* @see UriComponents#toUriString()
*/
@Override
public String toUriString() {
return (this.uriVariables.isEmpty() ?
build().encode().toUriString() :

View File

@@ -142,6 +142,7 @@ public class WebMvcStompEndpointRegistry implements StompEndpointRegistry {
return this;
}
@Override
public WebMvcStompEndpointRegistry setPreserveReceiveOrder(boolean preserveReceiveOrder) {
this.stompHandler.setPreserveReceiveOrder(preserveReceiveOrder);
return this;