Consistent use of @Deprecated(since = "6.0")

This commit is contained in:
Sam Brannen 2022-09-20 14:32:27 +02:00
parent 91bca55cbf
commit 321092ce6f
101 changed files with 174 additions and 174 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -33,7 +33,7 @@ import org.springframework.lang.Nullable;
* @see CachingConfigurerSupport
* @deprecated as of 6.0 in favor of implementing {@link JCacheConfigurer} directly
*/
@Deprecated
@Deprecated(since = "6.0")
public class JCacheConfigurerSupport extends CachingConfigurerSupport implements JCacheConfigurer {
@Override

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -31,7 +31,7 @@ import org.springframework.lang.Nullable;
* @see CachingConfigurer
* @deprecated as of 6.0 in favor of implementing {@link CachingConfigurer} directly
*/
@Deprecated
@Deprecated(since = "6.0")
public class CachingConfigurerSupport implements CachingConfigurer {
@Override

View File

@ -104,7 +104,7 @@ public interface TaskScheduler {
* for internal reasons (e.g. a pool overload handling policy or a pool shutdown in progress)
* @deprecated as of 6.0, in favor of {@link #schedule(Runnable, Instant)}
*/
@Deprecated
@Deprecated(since = "6.0")
default ScheduledFuture<?> schedule(Runnable task, Date startTime) {
return schedule(task, startTime.toInstant());
}
@ -139,7 +139,7 @@ public interface TaskScheduler {
* for internal reasons (e.g. a pool overload handling policy or a pool shutdown in progress)
* @deprecated as of 6.0, in favor of {@link #scheduleAtFixedRate(Runnable, Instant, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
default ScheduledFuture<?> scheduleAtFixedRate(Runnable task, Date startTime, long period) {
return scheduleAtFixedRate(task, startTime.toInstant(), Duration.ofMillis(period));
}
@ -170,7 +170,7 @@ public interface TaskScheduler {
* for internal reasons (e.g. a pool overload handling policy or a pool shutdown in progress)
* @deprecated as of 6.0, in favor of {@link #scheduleAtFixedRate(Runnable, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
default ScheduledFuture<?> scheduleAtFixedRate(Runnable task, long period) {
return scheduleAtFixedRate(task, Duration.ofMillis(period));
}
@ -208,7 +208,7 @@ public interface TaskScheduler {
* for internal reasons (e.g. a pool overload handling policy or a pool shutdown in progress)
* @deprecated as of 6.0, in favor of {@link #scheduleWithFixedDelay(Runnable, Instant, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
default ScheduledFuture<?> scheduleWithFixedDelay(Runnable task, Date startTime, long delay) {
return scheduleWithFixedDelay(task, startTime.toInstant(), Duration.ofMillis(delay));
}
@ -240,7 +240,7 @@ public interface TaskScheduler {
* for internal reasons (e.g. a pool overload handling policy or a pool shutdown in progress)
* @deprecated as of 6.0, in favor of {@link #scheduleWithFixedDelay(Runnable, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
default ScheduledFuture<?> scheduleWithFixedDelay(Runnable task, long delay) {
return scheduleWithFixedDelay(task, Duration.ofMillis(delay));
}

View File

@ -40,7 +40,7 @@ public interface Trigger {
* or {@code null} if the trigger won't fire anymore
* @deprecated as of 6.0, in favor of {@link #nextExecution(TriggerContext)}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
default Date nextExecutionTime(TriggerContext triggerContext) {
Instant instant = nextExecution(triggerContext);

View File

@ -47,7 +47,7 @@ public interface TriggerContext {
* @deprecated as of 6.0, in favor on {@link #lastScheduledExecution()}
*/
@Nullable
@Deprecated
@Deprecated(since = "6.0")
default Date lastScheduledExecutionTime() {
Instant instant = lastScheduledExecution();
return instant != null ? Date.from(instant) : null;
@ -66,7 +66,7 @@ public interface TriggerContext {
* or {@code null} if not scheduled before.
* @deprecated as of 6.0, in favor on {@link #lastActualExecution()}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
default Date lastActualExecutionTime() {
Instant instant = lastActualExecution();
@ -85,7 +85,7 @@ public interface TriggerContext {
* or {@code null} if not scheduled before.
* @deprecated as of 6.0, in favor on {@link #lastCompletion()}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
default Date lastCompletionTime() {
Instant instant = lastCompletion();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -30,7 +30,7 @@ import org.springframework.lang.Nullable;
* @since 4.1
* @deprecated as of 6.0 in favor of implementing {@link AsyncConfigurer} directly
*/
@Deprecated
@Deprecated(since = "6.0")
public class AsyncConfigurerSupport implements AsyncConfigurer {
@Override

View File

@ -47,7 +47,7 @@ import org.springframework.util.concurrent.SuccessCallback;
* @see #forExecutionException(Throwable)
* @deprecated as of 6.0, in favor of {@link CompletableFuture}
*/
@Deprecated
@Deprecated(since = "6.0")
public class AsyncResult<V> implements ListenableFuture<V> {
@Nullable

View File

@ -36,7 +36,7 @@ public class FixedDelayTask extends IntervalTask {
* @param initialDelay the initial delay before first execution of the task
* @deprecated as of 6.0, in favor on {@link #FixedDelayTask(Runnable, Duration, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public FixedDelayTask(Runnable runnable, long interval, long initialDelay) {
super(runnable, interval, initialDelay);
}

View File

@ -36,7 +36,7 @@ public class FixedRateTask extends IntervalTask {
* @param initialDelay the initial delay before first execution of the task
* @deprecated as of 6.0, in favor on {@link #FixedRateTask(Runnable, Duration, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public FixedRateTask(Runnable runnable, long interval, long initialDelay) {
super(runnable, interval, initialDelay);
}

View File

@ -45,7 +45,7 @@ public class IntervalTask extends Task {
* @param initialDelay the initial delay before first execution of the task
* @deprecated as of 6.0, in favor on {@link #IntervalTask(Runnable, Duration, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public IntervalTask(Runnable runnable, long interval, long initialDelay) {
this(runnable, Duration.ofMillis(interval), Duration.ofMillis(initialDelay));
}
@ -56,7 +56,7 @@ public class IntervalTask extends Task {
* @param interval how often in milliseconds the task should be executed
* @deprecated as of 6.0, in favor on {@link #IntervalTask(Runnable, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public IntervalTask(Runnable runnable, long interval) {
this(runnable, Duration.ofMillis(interval), Duration.ZERO);
}
@ -105,7 +105,7 @@ public class IntervalTask extends Task {
* Return how often in milliseconds the task should be executed.
* @deprecated as of 6.0, in favor of {@link #getIntervalDuration()}
*/
@Deprecated
@Deprecated(since = "6.0")
public long getInterval() {
return this.interval.toMillis();
}
@ -122,7 +122,7 @@ public class IntervalTask extends Task {
* Return the initial delay before first execution of the task.
* @deprecated as of 6.0, in favor of {@link #getInitialDelayDuration()}
*/
@Deprecated
@Deprecated(since = "6.0")
public long getInitialDelay() {
return this.initialDelay.toMillis();
}

View File

@ -294,7 +294,7 @@ public class ScheduledTaskRegistrar implements ScheduledTaskHolder, Initializing
* Add a {@code Runnable} task to be triggered at the given fixed-rate interval.
* @deprecated as of 6.0, in favor of {@link #addFixedRateTask(Runnable, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void addFixedRateTask(Runnable task, long interval) {
addFixedRateTask(new IntervalTask(task, Duration.ofMillis(interval)));
}
@ -324,7 +324,7 @@ public class ScheduledTaskRegistrar implements ScheduledTaskHolder, Initializing
* Add a Runnable task to be triggered with the given fixed delay.
* @deprecated as of 6.0, in favor of {@link #addFixedDelayTask(Runnable, Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void addFixedDelayTask(Runnable task, long delay) {
addFixedDelayTask(new IntervalTask(task, Duration.ofMillis(delay)));
}

View File

@ -64,7 +64,7 @@ public class PeriodicTrigger implements Trigger {
* Create a trigger with the given period in milliseconds.
* @deprecated as of 6.0, in favor on {@link #PeriodicTrigger(Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public PeriodicTrigger(long period) {
this(period, null);
}
@ -75,7 +75,7 @@ public class PeriodicTrigger implements Trigger {
* configured on this Trigger later via {@link #setInitialDelay(long)}.
* @deprecated as of 6.0, in favor on {@link #PeriodicTrigger(Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public PeriodicTrigger(long period, @Nullable TimeUnit timeUnit) {
this(toDuration(period, timeUnit), timeUnit);
}
@ -115,7 +115,7 @@ public class PeriodicTrigger implements Trigger {
* @since 5.0.2
* @deprecated as of 6.0, in favor on {@link #getPeriodDuration()}
*/
@Deprecated
@Deprecated(since = "6.0")
public long getPeriod() {
if (this.chronoUnit != null) {
return this.period.get(this.chronoUnit);
@ -138,7 +138,7 @@ public class PeriodicTrigger implements Trigger {
* @since 5.0.2
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public TimeUnit getTimeUnit() {
if (this.chronoUnit != null) {
return TimeUnit.of(this.chronoUnit);
@ -154,7 +154,7 @@ public class PeriodicTrigger implements Trigger {
* provided upon instantiation, the default is milliseconds.
* @deprecated as of 6.0, in favor of {@link #setInitialDelay(Duration)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setInitialDelay(long initialDelay) {
if (this.chronoUnit != null) {
this.initialDelay = Duration.of(initialDelay, this.chronoUnit);
@ -177,7 +177,7 @@ public class PeriodicTrigger implements Trigger {
* @since 5.0.2
* @deprecated as of 6.0, in favor on {@link #getInitialDelayDuration()}
*/
@Deprecated
@Deprecated(since = "6.0")
public long getInitialDelay() {
Duration initialDelay = this.initialDelay;
if (initialDelay != null) {

View File

@ -59,7 +59,7 @@ public class SimpleTriggerContext implements TriggerContext {
* @param lastCompletionTime last completion time
* @deprecated as of 6.0, in favor of {@link #SimpleTriggerContext(Instant, Instant, Instant)}
*/
@Deprecated
@Deprecated(since = "6.0")
public SimpleTriggerContext(@Nullable Date lastScheduledExecutionTime, @Nullable Date lastActualExecutionTime,
@Nullable Date lastCompletionTime) {
@ -106,7 +106,7 @@ public class SimpleTriggerContext implements TriggerContext {
* @param lastCompletionTime last completion time
* @deprecated as of 6.0, in favor of {@link #update(Instant, Instant, Instant)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void update(@Nullable Date lastScheduledExecutionTime, @Nullable Date lastActualExecutionTime,
@Nullable Date lastCompletionTime) {

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2022 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.
@ -26,7 +26,7 @@ import org.springframework.lang.Nullable;
* @author Juergen Hoeller
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public interface HierarchicalThemeSource extends ThemeSource {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2022 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.
@ -30,7 +30,7 @@ import org.springframework.context.MessageSource;
* @see org.springframework.web.servlet.ThemeResolver
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public interface Theme {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2022 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.
@ -28,7 +28,7 @@ import org.springframework.lang.Nullable;
* @see Theme
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public interface ThemeSource {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 the original author or authors.
* Copyright 2002-2022 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.
@ -33,7 +33,7 @@ import org.springframework.ui.context.ThemeSource;
* @see UiApplicationContextUtils
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class DelegatingThemeSource implements HierarchicalThemeSource {
@Nullable

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 the original author or authors.
* Copyright 2002-2022 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.
@ -44,7 +44,7 @@ import org.springframework.ui.context.ThemeSource;
* @see org.springframework.context.support.ResourceBundleMessageSource
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class ResourceBundleThemeSource implements HierarchicalThemeSource, BeanClassLoaderAware {
protected final Log logger = LogFactory.getLog(getClass());

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2022 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.
@ -28,7 +28,7 @@ import org.springframework.util.Assert;
* @since 17.06.2003
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class SimpleTheme implements Theme {
private final String name;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -33,7 +33,7 @@ import org.springframework.ui.context.ThemeSource;
* @since 17.06.2003
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public abstract class UiApplicationContextUtils {
/**

View File

@ -40,7 +40,7 @@ public abstract class NestedExceptionUtils {
* @deprecated as of 6.0, in favor of custom exception messages
* with selective inclusion of cause messages
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
public static String buildMessage(@Nullable String message, @Nullable Throwable cause) {
if (cause == null) {

View File

@ -114,7 +114,7 @@ public interface DataBuffer {
* @deprecated as of 6.0, in favor of {@link #ensureWritable(int)}, which
* has different semantics
*/
@Deprecated
@Deprecated(since = "6.0")
DataBuffer capacity(int capacity);
/**
@ -126,7 +126,7 @@ public interface DataBuffer {
* @since 5.1.4
* @deprecated since 6.0, in favor of {@link #ensureWritable(int)}
*/
@Deprecated
@Deprecated(since = "6.0")
default DataBuffer ensureCapacity(int capacity) {
return ensureWritable(capacity);
}
@ -304,7 +304,7 @@ public interface DataBuffer {
* @deprecated as of 6.0, in favor of {@link #split(int)}, which
* has different semantics
*/
@Deprecated
@Deprecated(since = "6.0")
DataBuffer slice(int index, int length);
/**
@ -322,7 +322,7 @@ public interface DataBuffer {
* @deprecated as of 6.0, in favor of {@link #split(int)}, which
* has different semantics
*/
@Deprecated
@Deprecated(since = "6.0")
default DataBuffer retainedSlice(int index, int length) {
return DataBufferUtils.retain(slice(index, length));
}
@ -356,7 +356,7 @@ public interface DataBuffer {
* @deprecated as of 6.0, in favor of {@link #toByteBuffer()}, which does
* <strong>not</strong> share data and returns a copy.
*/
@Deprecated
@Deprecated(since = "6.0")
ByteBuffer asByteBuffer();
/**
@ -371,7 +371,7 @@ public interface DataBuffer {
* @deprecated as of 6.0, in favor of {@link #toByteBuffer(int, int)}, which
* does <strong>not</strong> share data and returns a copy.
*/
@Deprecated
@Deprecated(since = "6.0")
ByteBuffer asByteBuffer(int index, int length);
/**

View File

@ -36,7 +36,7 @@ public interface DataBufferFactory {
* @return the allocated buffer
* @deprecated as of 6.0, in favor of {@link #allocateBuffer(int)}
*/
@Deprecated
@Deprecated(since = "6.0")
DataBuffer allocateBuffer();
/**

View File

@ -270,7 +270,7 @@ public class SpringFactoriesLoader {
* @see #loadFactories
* @deprecated as of 6.0 in favor of {@link #load(Class, ArgumentResolver, FailureHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
public static List<String> loadFactoryNames(Class<?> factoryType, @Nullable ClassLoader classLoader) {
return forDefaultResourceLocation(classLoader).loadFactoryNames(factoryType);
}

View File

@ -31,7 +31,7 @@ import org.springframework.util.concurrent.ListenableFuture;
* {@link AsyncTaskExecutor#submitCompletable(Runnable)} and
* {@link AsyncTaskExecutor#submitCompletable(Callable)}
*/
@Deprecated
@Deprecated(since = "6.0")
public interface AsyncListenableTaskExecutor extends AsyncTaskExecutor {
/**

View File

@ -159,7 +159,7 @@ public final class ConcurrentLruCache<K, V> {
* Return the maximum number of entries in the cache.
* @deprecated in favor of {@link #capacity()} as of 6.0.
*/
@Deprecated
@Deprecated(since = "6.0")
public int sizeLimit() {
return this.capacity;
}

View File

@ -708,7 +708,7 @@ public class MimeType implements Comparable<MimeType>, Serializable {
* @param <T> the type of mime types that may be compared by this comparator
* @deprecated As of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static class SpecificityComparator<T extends MimeType> implements Comparator<T> {
@Override

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -55,7 +55,7 @@ public abstract class MimeTypeUtils {
* Comparator formally used by {@link #sortBySpecificity(List)}.
* @deprecated As of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static final Comparator<MimeType> SPECIFICITY_COMPARATOR = new MimeType.SpecificityComparator<>();
/**

View File

@ -215,7 +215,7 @@ public abstract class StreamUtils {
* @since 4.2.2
* @deprecated as of 6.0 in favor of {@link InputStream#nullInputStream()}
*/
@Deprecated
@Deprecated(since = "6.0")
public static InputStream emptyInput() {
return InputStream.nullInputStream();
}

View File

@ -32,7 +32,7 @@ import java.util.concurrent.TimeoutException;
* @param <T> the result type returned by this Future's {@code get} method
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class CompletableToListenableFutureAdapter<T> implements ListenableFuture<T> {
private final CompletableFuture<T> completableFuture;

View File

@ -26,7 +26,7 @@ import java.util.function.BiConsumer;
* @deprecated as of 6.0, in favor of
* {@link java.util.concurrent.CompletableFuture#whenComplete(BiConsumer)}
*/
@Deprecated
@Deprecated(since = "6.0")
@FunctionalInterface
public interface FailureCallback {

View File

@ -35,7 +35,7 @@ import org.springframework.util.Assert;
* @param <S> the type of the adaptee's {@code Future}
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public abstract class FutureAdapter<T, S> implements Future<T> {
private final Future<S> adaptee;

View File

@ -34,7 +34,7 @@ import java.util.function.BiConsumer;
* @param <T> the result type returned by this Future's {@code get} method
* @deprecated as of 6.0, in favor of {@link CompletableFuture}
*/
@Deprecated
@Deprecated(since = "6.0")
public interface ListenableFuture<T> extends Future<T> {
/**
@ -43,7 +43,7 @@ public interface ListenableFuture<T> extends Future<T> {
* @deprecated as of 6.0, in favor of
* {@link CompletableFuture#whenComplete(BiConsumer)}
*/
@Deprecated
@Deprecated(since = "6.0")
void addCallback(ListenableFutureCallback<? super T> callback);
/**
@ -54,7 +54,7 @@ public interface ListenableFuture<T> extends Future<T> {
* @deprecated as of 6.0, in favor of
* {@link CompletableFuture#whenComplete(BiConsumer)}
*/
@Deprecated
@Deprecated(since = "6.0")
void addCallback(SuccessCallback<? super T> successCallback, FailureCallback failureCallback);

View File

@ -34,7 +34,7 @@ import org.springframework.lang.Nullable;
* @deprecated as of 6.0, in favor of
* {@link java.util.concurrent.CompletableFuture}
*/
@Deprecated
@Deprecated(since = "6.0")
public abstract class ListenableFutureAdapter<T, S> extends FutureAdapter<T, S> implements ListenableFuture<T> {
/**

View File

@ -29,7 +29,7 @@ import java.util.function.BiConsumer;
* @deprecated as of 6.0, in favor of
* {@link java.util.concurrent.CompletableFuture#whenComplete(BiConsumer)}
*/
@Deprecated
@Deprecated(since = "6.0")
public interface ListenableFutureCallback<T> extends SuccessCallback<T>, FailureCallback {
}

View File

@ -35,7 +35,7 @@ import org.springframework.util.Assert;
* @param <T> the callback result type
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class ListenableFutureCallbackRegistry<T> {
private final Queue<SuccessCallback<? super T>> successCallbacks = new ArrayDeque<>(1);

View File

@ -31,7 +31,7 @@ import org.springframework.lang.Nullable;
* @param <T> the result type returned by this Future's {@code get} method
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class ListenableFutureTask<T> extends FutureTask<T> implements ListenableFuture<T> {
private final ListenableFutureCallbackRegistry<T> callbacks = new ListenableFutureCallbackRegistry<>();

View File

@ -29,7 +29,7 @@ import reactor.core.publisher.Mono;
* @param <T> the object type
* @deprecated as of 6.0, in favor of {@link Mono#toFuture()}
*/
@Deprecated
@Deprecated(since = "6.0")
public class MonoToListenableFutureAdapter<T> extends CompletableToListenableFutureAdapter<T> {
public MonoToListenableFutureAdapter(Mono<T> mono) {

View File

@ -38,7 +38,7 @@ import org.springframework.util.Assert;
* @param <T> the result type returned by this Future's {@code get} method
* @deprecated as of 6.0, in favor of {@link CompletableFuture}
*/
@Deprecated
@Deprecated(since = "6.0")
public class SettableListenableFuture<T> implements ListenableFuture<T> {
private static final Callable<Object> DUMMY_CALLABLE = () -> {

View File

@ -29,7 +29,7 @@ import org.springframework.lang.Nullable;
* @deprecated as of 6.0, in favor of
* {@link java.util.concurrent.CompletableFuture#whenComplete(BiConsumer)}
*/
@Deprecated
@Deprecated(since = "6.0")
@FunctionalInterface
public interface SuccessCallback<T> {

View File

@ -67,7 +67,7 @@ public interface AsyncHandlerMethodReturnValueHandler extends HandlerMethodRetur
* @deprecated as of 6.0, in favor of
* {@link #toCompletableFuture(Object, MethodParameter)}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
default org.springframework.util.concurrent.ListenableFuture<?> toListenableFuture(
Object returnValue, MethodParameter returnType) {

View File

@ -28,7 +28,7 @@ import org.springframework.util.concurrent.ListenableFuture;
* @since 4.2
* @deprecated as of 6.0, in favor of {@link CompletableFutureReturnValueHandler}
*/
@Deprecated
@Deprecated(since = "6.0")
public class ListenableFutureReturnValueHandler extends AbstractAsyncReturnValueHandler {
@Override

View File

@ -35,7 +35,7 @@ public interface ConnectionHandlingStompSession extends StompSession, StompTcpCo
* Return a future that will complete when the session is ready for use.
* @deprecated as of 6.0, in favor of {@link #getSession()}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<StompSession> getSessionFuture() {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
getSession());

View File

@ -96,7 +96,7 @@ public class ReactorNettyTcpStompClient extends StompClientSupport {
* @return a ListenableFuture for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(StompSessionHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
StompSessionHandler handler) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
@ -122,7 +122,7 @@ public class ReactorNettyTcpStompClient extends StompClientSupport {
* @return a ListenableFuture for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(StompHeaders, StompSessionHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
@Nullable StompHeaders connectHeaders, StompSessionHandler handler) {
ConnectionHandlingStompSession session = createSession(connectHeaders, handler);

View File

@ -37,7 +37,7 @@ public interface TcpConnection<P> extends Closeable {
* message was successfully sent
* @deprecated as of 6.0, in favor of {@link #sendAsync(Message)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<Void> send(Message<P> message) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
sendAsync(message));

View File

@ -34,7 +34,7 @@ public interface TcpOperations<P> {
* connection is successfully established
* @deprecated as of 6.0, in favor of {@link #connectAsync(TcpConnectionHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<Void> connect(
TcpConnectionHandler<P> connectionHandler) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
@ -58,7 +58,7 @@ public interface TcpOperations<P> {
* initial connection is successfully established
* @deprecated as of 6.0, in favor of {@link #connectAsync(TcpConnectionHandler, ReconnectStrategy)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<Void> connect(
TcpConnectionHandler<P> connectionHandler, ReconnectStrategy reconnectStrategy) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
@ -81,7 +81,7 @@ public interface TcpOperations<P> {
* connection is successfully closed
* @deprecated as of 6.0, in favor of {@link #shutdownAsync()}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<Void> shutdown() {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
shutdownAsync());

View File

@ -240,7 +240,7 @@ public final class MockServerHttpRequest extends AbstractServerHttpRequest {
* @since 5.2.7
* @deprecated as of Spring Framework 6.0 in favor of {@link #method(HttpMethod, String, Object...)}
*/
@Deprecated
@Deprecated(since = "6.0")
public static BodyBuilder method(String httpMethod, String uri, Object... vars) {
Assert.isTrue(StringUtils.hasText(httpMethod), "HTTP method is required.");
return new DefaultBodyBuilder(HttpMethod.valueOf(httpMethod), toUri(uri, vars));

View File

@ -57,7 +57,7 @@ public interface ContextLoader {
* @deprecated as of Spring Framework 6.0, in favor of methods defined in the
* {@link SmartContextLoader} SPI
*/
@Deprecated
@Deprecated(since = "6.0")
String[] processLocations(Class<?> clazz, String... locations);
/**
@ -84,7 +84,7 @@ public interface ContextLoader {
* @deprecated as of Spring Framework 6.0, in favor of methods defined in the
* {@link SmartContextLoader} SPI
*/
@Deprecated
@Deprecated(since = "6.0")
ApplicationContext loadContext(String... locations) throws Exception;
}

View File

@ -256,7 +256,7 @@ public abstract class AbstractGenericContextLoader extends AbstractContextLoader
* @see #loadContext(MergedContextConfiguration)
* @deprecated as of Spring Framework 6.0, in favor of {@link #loadContext(MergedContextConfiguration)}
*/
@Deprecated
@Deprecated(since = "6.0")
@Override
public final ConfigurableApplicationContext loadContext(String... locations) throws Exception {
if (logger.isDebugEnabled()) {

View File

@ -181,7 +181,7 @@ public class ExchangeResult {
* @since 5.1.10
* @deprecated as of 6.0, in favor of {@link #getStatus()}
*/
@Deprecated
@Deprecated(since = "6.0")
public int getRawStatusCode() {
return this.response.getRawStatusCode();
}

View File

@ -361,7 +361,7 @@ public interface MockMvcWebTestClient {
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
ControllerSpec useTrailingSlashPatternMatch(boolean useTrailingSlashPatternMatch);
/**

View File

@ -345,7 +345,7 @@ public class StandaloneMockMvcBuilder extends AbstractMockMvcBuilder<StandaloneM
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public StandaloneMockMvcBuilder setUseTrailingSlashPatternMatch(boolean useTrailingSlashPatternMatch) {
this.useTrailingSlashPatternMatch = useTrailingSlashPatternMatch;
return this;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -29,7 +29,7 @@ import org.springframework.transaction.jta.JtaTransactionManager;
* @since 4.1.1
* @deprecated as of 6.0, in favor of a straight {@link JtaTransactionManager} definition
*/
@Deprecated
@Deprecated(since = "6.0")
public class JtaTransactionManagerFactoryBean implements FactoryBean<JtaTransactionManager>, InitializingBean {
private final JtaTransactionManager transactionManager = new JtaTransactionManager();

View File

@ -42,7 +42,7 @@ public interface HttpRequest extends HttpMessage {
* @deprecated as of Spring Framework 6.0 in favor of {@link #getMethod()} and
* {@link HttpMethod#name()}
*/
@Deprecated
@Deprecated(since = "6.0")
String getMethodValue();
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -823,7 +823,7 @@ public class MediaType extends MimeType implements Serializable {
* @param mediaTypes the list of media types to be sorted
* @deprecated As of 6.0, in favor of {@link MimeTypeUtils#sortBySpecificity(List)}
*/
@Deprecated
@Deprecated(since = "6.0")
public static void sortBySpecificity(List<MediaType> mediaTypes) {
Assert.notNull(mediaTypes, "'mediaTypes' must not be null");
if (mediaTypes.size() > 1) {
@ -852,7 +852,7 @@ public class MediaType extends MimeType implements Serializable {
* @see #getQualityValue()
* @deprecated As of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static void sortByQualityValue(List<MediaType> mediaTypes) {
Assert.notNull(mediaTypes, "'mediaTypes' must not be null");
if (mediaTypes.size() > 1) {
@ -865,7 +865,7 @@ public class MediaType extends MimeType implements Serializable {
* primary criteria and quality value the secondary.
* @deprecated As of 6.0, in favor of {@link MimeTypeUtils#sortBySpecificity(List)}
*/
@Deprecated
@Deprecated(since = "6.0")
public static void sortBySpecificityAndQuality(List<MediaType> mediaTypes) {
Assert.notNull(mediaTypes, "'mediaTypes' must not be null");
if (mediaTypes.size() > 1) {
@ -878,7 +878,7 @@ public class MediaType extends MimeType implements Serializable {
* Comparator used by {@link #sortByQualityValue(List)}.
* @deprecated As of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static final Comparator<MediaType> QUALITY_VALUE_COMPARATOR = (mediaType1, mediaType2) -> {
double quality1 = mediaType1.getQualityValue();
double quality2 = mediaType2.getQualityValue();
@ -918,7 +918,7 @@ public class MediaType extends MimeType implements Serializable {
* Comparator used by {@link #sortBySpecificity(List)}.
* @deprecated As of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static final Comparator<MediaType> SPECIFICITY_COMPARATOR = new SpecificityComparator<>() {
@Override

View File

@ -157,7 +157,7 @@ public class ResponseEntity<T> extends HttpEntity<T> {
* @since 4.3
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
public int getStatusCodeValue() {
if (this.status instanceof HttpStatusCode statusCode) {
return statusCode.value();

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2012 the original author or authors.
* Copyright 2002-2022 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.
@ -27,7 +27,7 @@ import org.springframework.http.HttpStatusCode;
* @since 3.1.1
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public abstract class AbstractClientHttpResponse implements ClientHttpResponse {
@Override

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -50,7 +50,7 @@ public interface ClientHttpResponse extends HttpInputMessage, Closeable {
* @see #getStatusCode()
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
int getRawStatusCode() throws IOException;
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 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.
@ -53,7 +53,7 @@ public interface ClientHttpResponse extends ReactiveHttpInputMessage {
* @see #getStatusCode()
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
int getRawStatusCode();
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -68,7 +68,7 @@ public interface ServerHttpResponse extends ReactiveHttpOutputMessage {
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Nullable
@Deprecated
@Deprecated(since = "6.0")
default Integer getRawStatusCode() {
HttpStatusCode httpStatus = getStatusCode();
return (httpStatus != null ? httpStatus.value() : null);

View File

@ -107,7 +107,7 @@ public class RestClientResponseException extends RestClientException {
* Return the raw HTTP status code value.
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
public int getRawStatusCode() {
return this.statusCode.value();
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -115,7 +115,7 @@ public class UnknownContentTypeException extends RestClientException {
* Return the raw HTTP status code value.
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
public int getRawStatusCode() {
return this.statusCode.value();
}

View File

@ -87,7 +87,7 @@ public class ModelAndViewContainer {
* @deprecated as of 6.0 without a replacement; once removed, the default
* model will always be ignored on redirect
*/
@Deprecated
@Deprecated(since = "6.0")
public void setIgnoreDefaultModelOnRedirect(boolean ignoreDefaultModelOnRedirect) {
this.ignoreDefaultModelOnRedirect = ignoreDefaultModelOnRedirect;
}

View File

@ -81,7 +81,7 @@ public class MethodNotAllowedException extends ResponseStatusException {
* @since 5.1.13
* @deprecated as of 6.0 in favor of {@link #getHeaders()}
*/
@Deprecated
@Deprecated(since = "6.0")
@Override
public HttpHeaders getResponseHeaders() {
return getHeaders();

View File

@ -76,7 +76,7 @@ public class NotAcceptableStatusException extends ResponseStatusException {
* @since 5.1.13
* @deprecated as of 6.0 in favor of {@link #getHeaders()}
*/
@Deprecated
@Deprecated(since = "6.0")
@Override
public HttpHeaders getResponseHeaders() {
return getHeaders();

View File

@ -104,7 +104,7 @@ public class ResponseStatusException extends ErrorResponseException {
* @since 5.1.13
* @deprecated as of 6.0 in favor of {@link #getHeaders()}
*/
@Deprecated
@Deprecated(since = "6.0")
public HttpHeaders getResponseHeaders() {
return HttpHeaders.EMPTY;
}

View File

@ -155,7 +155,7 @@ public class UnsupportedMediaTypeStatusException extends ResponseStatusException
* Delegates to {@link #getHeaders()}.
* @deprecated as of 6.0 in favor of {@link #getHeaders()}
*/
@Deprecated
@Deprecated(since = "6.0")
@Override
public HttpHeaders getResponseHeaders() {
return getHeaders();

View File

@ -134,7 +134,7 @@ public class ResponseStatusExceptionHandler implements WebExceptionHandler {
* @since 5.3
* @deprecated as of 6.0, in favor of {@link #determineStatus(Throwable)}
*/
@Deprecated
@Deprecated(since = "6.0")
protected int determineRawStatusCode(Throwable ex) {
if (ex instanceof ResponseStatusException responseStatusException) {
return responseStatusException.getStatusCode().value();

View File

@ -41,7 +41,7 @@ import org.springframework.lang.Nullable;
* @see org.springframework.core.NestedRuntimeException
* @deprecated as of 6.0, in favor of standard {@link ServletException} nesting
*/
@Deprecated
@Deprecated(since = "6.0")
public class NestedServletException extends ServletException {
/** Use serialVersionUID from Spring 1.2 for interoperability. */

View File

@ -54,7 +54,7 @@ public class PathPatternParser {
* 6.0 in favor of configuring explicit redirects through a proxy,
* Servlet/web filter, or a controller.
*/
@Deprecated
@Deprecated(since = "6.0")
public void setMatchOptionalTrailingSeparator(boolean matchOptionalTrailingSeparator) {
this.matchOptionalTrailingSeparator = matchOptionalTrailingSeparator;
}
@ -63,7 +63,7 @@ public class PathPatternParser {
* Whether optional trailing slashing match is enabled.
* @deprecated as of 6.0 together with {@link #setMatchOptionalTrailingSeparator(boolean)}.
*/
@Deprecated
@Deprecated(since = "6.0")
public boolean isMatchOptionalTrailingSeparator() {
return this.matchOptionalTrailingSeparator;
}

View File

@ -61,7 +61,7 @@ public class PathMatchConfigurer {
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public PathMatchConfigurer setUseTrailingSlashMatch(Boolean trailingSlashMatch) {
this.trailingSlashMatch = trailingSlashMatch;
return this;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -63,7 +63,7 @@ public interface ClientResponse {
* @since 5.1
* @deprecated as of 6.0, in favor of {@link #statusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
int rawStatusCode();
/**

View File

@ -174,7 +174,7 @@ public class WebClientResponseException extends WebClientException {
* Return the raw HTTP status code value.
* @deprecated as of 6.0, in favor of {@link #getStatusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
public int getRawStatusCode() {
return this.statusCode.value();
}

View File

@ -75,7 +75,7 @@ public interface ServerRequest {
* @return the HTTP method as a String
* @deprecated as of 6.0, in favor of {@link #method()}
*/
@Deprecated
@Deprecated(since = "6.0")
String methodName();
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2019 the original author or authors.
* Copyright 2002-2022 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.
@ -71,7 +71,7 @@ public interface ServerResponse {
* @since 5.2
* @deprecated as of 6.0, in favor of {@link #statusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
int rawStatusCode();
/**

View File

@ -98,7 +98,7 @@ public abstract class AbstractHandlerMapping extends ApplicationObjectSupport
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setUseTrailingSlashMatch(boolean trailingSlashMatch) {
this.patternParser.setMatchOptionalTrailingSeparator(trailingSlashMatch);
}

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2017 the original author or authors.
* Copyright 2002-2022 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.
@ -47,7 +47,7 @@ import org.springframework.lang.Nullable;
* @see org.springframework.ui.context.ThemeSource
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public interface ThemeResolver {
/**

View File

@ -111,7 +111,7 @@ public class PathMatchConfigurer {
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public PathMatchConfigurer setUseTrailingSlashMatch(Boolean trailingSlashMatch) {
this.trailingSlashMatch = trailingSlashMatch;
return this;

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2019 the original author or authors.
* Copyright 2002-2022 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.
@ -70,7 +70,7 @@ public interface ServerResponse {
* @return the status as an integer
* @deprecated as of 6.0, in favor of {@link #statusCode()}
*/
@Deprecated
@Deprecated(since = "6.0")
int rawStatusCode();
/**

View File

@ -181,7 +181,7 @@ public abstract class AbstractHandlerMapping extends WebApplicationObjectSupport
* @see org.springframework.web.util.UrlPathHelper#setAlwaysUseFullPath(boolean)
* @deprecated as of 6.0, in favor of using {@link #setUrlPathHelper(UrlPathHelper)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setAlwaysUseFullPath(boolean alwaysUseFullPath) {
this.urlPathHelper.setAlwaysUseFullPath(alwaysUseFullPath);
if (this.corsConfigurationSource instanceof UrlBasedCorsConfigurationSource urlConfigSource) {
@ -196,7 +196,7 @@ public abstract class AbstractHandlerMapping extends WebApplicationObjectSupport
* @see org.springframework.web.util.UrlPathHelper#setUrlDecode(boolean)
* @deprecated as of 6.0, in favor of using {@link #setUrlPathHelper(UrlPathHelper)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setUrlDecode(boolean urlDecode) {
this.urlPathHelper.setUrlDecode(urlDecode);
if (this.corsConfigurationSource instanceof UrlBasedCorsConfigurationSource urlConfigSource) {
@ -211,7 +211,7 @@ public abstract class AbstractHandlerMapping extends WebApplicationObjectSupport
* @see org.springframework.web.util.UrlPathHelper#setRemoveSemicolonContent(boolean)
* @deprecated as of 6.0, in favor of using {@link #setUrlPathHelper(UrlPathHelper)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setRemoveSemicolonContent(boolean removeSemicolonContent) {
this.urlPathHelper.setRemoveSemicolonContent(removeSemicolonContent);
if (this.corsConfigurationSource instanceof UrlBasedCorsConfigurationSource urlConfigSource) {

View File

@ -108,7 +108,7 @@ public abstract class AbstractUrlHandlerMapping extends AbstractHandlerMapping i
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setUseTrailingSlashMatch(boolean useTrailingSlashMatch) {
this.useTrailingSlashMatch = useTrailingSlashMatch;
if (getPatternParser() != null) {

View File

@ -377,7 +377,7 @@ public class CookieLocaleResolver extends CookieGenerator implements LocaleConte
* @see jakarta.servlet.http.HttpServletRequest#getLocale()
* @deprecated as of 6.0, in favor of {@link #setDefaultLocaleFunction(Function)}
*/
@Deprecated
@Deprecated(since = "6.0")
protected Locale determineDefaultLocale(HttpServletRequest request) {
return this.defaultLocaleFunction.apply(request);
}
@ -392,7 +392,7 @@ public class CookieLocaleResolver extends CookieGenerator implements LocaleConte
* @see #setDefaultTimeZone
* @deprecated as of 6.0, in favor of {@link #setDefaultTimeZoneFunction(Function)}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
protected TimeZone determineDefaultTimeZone(HttpServletRequest request) {
return this.defaultTimeZoneFunction.apply(request);

View File

@ -208,7 +208,7 @@ public class SessionLocaleResolver extends AbstractLocaleContextResolver {
* @see jakarta.servlet.http.HttpServletRequest#getLocale()
* @deprecated as of 6.0, in favor of {@link #setDefaultLocaleFunction(Function)}
*/
@Deprecated
@Deprecated(since = "6.0")
protected Locale determineDefaultLocale(HttpServletRequest request) {
return this.defaultLocaleFunction.apply(request);
}
@ -223,7 +223,7 @@ public class SessionLocaleResolver extends AbstractLocaleContextResolver {
* @see #setDefaultTimeZone
* @deprecated as of 6.0, in favor of {@link #setDefaultTimeZoneFunction(Function)}
*/
@Deprecated
@Deprecated(since = "6.0")
@Nullable
protected TimeZone determineDefaultTimeZone(HttpServletRequest request) {
return this.defaultTimeZoneFunction.apply(request);

View File

@ -954,7 +954,7 @@ public final class RequestMappingInfo implements RequestCondition<RequestMapping
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setTrailingSlashMatch(boolean trailingSlashMatch) {
this.trailingSlashMatch = trailingSlashMatch;
}
@ -963,7 +963,7 @@ public final class RequestMappingInfo implements RequestCondition<RequestMapping
* Return whether to apply trailing slash matching in PatternsRequestCondition.
* @deprecated as of 6.0 together with {@link #setTrailingSlashMatch(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public boolean useTrailingSlashMatch() {
return this.trailingSlashMatch;
}

View File

@ -479,7 +479,7 @@ public class RequestMappingHandlerAdapter extends AbstractHandlerMethodAdapter
* @deprecated as of 6.0 without a replacement; once removed, the default
* model will always be ignored on redirect
*/
@Deprecated
@Deprecated(since = "6.0")
public void setIgnoreDefaultModelOnRedirect(boolean ignoreDefaultModelOnRedirect) {
this.ignoreDefaultModelOnRedirect = ignoreDefaultModelOnRedirect;
}

View File

@ -145,7 +145,7 @@ public class RequestMappingHandlerMapping extends RequestMappingInfoHandlerMappi
* @deprecated as of 6.0, see
* {@link PathPatternParser#setMatchOptionalTrailingSeparator(boolean)}
*/
@Deprecated
@Deprecated(since = "6.0")
public void setUseTrailingSlashMatch(boolean useTrailingSlashMatch) {
this.useTrailingSlashMatch = useTrailingSlashMatch;
if (getPatternParser() != null) {

View File

@ -80,7 +80,7 @@ public class RequestContext {
* @see org.springframework.web.servlet.theme.AbstractThemeResolver#ORIGINAL_DEFAULT_THEME_NAME
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public static final String DEFAULT_THEME_NAME = "theme";
/**
@ -392,7 +392,7 @@ public class RequestContext {
* <p>Resolved lazily for more efficiency when theme support is not being used.
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.ui.context.Theme getTheme() {
if (this.theme == null) {
// Lazily determine theme to use for this RequestContext.
@ -431,7 +431,7 @@ public class RequestContext {
* @see org.springframework.web.servlet.ThemeResolver#setThemeName
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public void changeTheme(@Nullable org.springframework.ui.context.Theme theme) {
org.springframework.web.servlet.ThemeResolver themeResolver = RequestContextUtils.getThemeResolver(this.request);
if (themeResolver == null) {

View File

@ -185,7 +185,7 @@ public abstract class RequestContextUtils {
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated
@Deprecated(since = "6.0")
public static org.springframework.web.servlet.ThemeResolver getThemeResolver(HttpServletRequest request) {
return (org.springframework.web.servlet.ThemeResolver) request.getAttribute(DispatcherServlet.THEME_RESOLVER_ATTRIBUTE);
}
@ -198,7 +198,7 @@ public abstract class RequestContextUtils {
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated
@Deprecated(since = "6.0")
public static org.springframework.ui.context.ThemeSource getThemeSource(HttpServletRequest request) {
return (org.springframework.ui.context.ThemeSource) request.getAttribute(DispatcherServlet.THEME_SOURCE_ATTRIBUTE);
}
@ -212,7 +212,7 @@ public abstract class RequestContextUtils {
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated
@Deprecated(since = "6.0")
public static org.springframework.ui.context.Theme getTheme(HttpServletRequest request) {
org.springframework.web.servlet.ThemeResolver themeResolver = getThemeResolver(request);
org.springframework.ui.context.ThemeSource themeSource = getThemeSource(request);

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 the original author or authors.
* Copyright 2002-2022 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.
@ -125,7 +125,7 @@ import org.springframework.context.NoSuchMessageException;
* @deprecated as of 6.0, with no direct replacement
*/
@SuppressWarnings("serial")
@Deprecated
@Deprecated(since = "6.0")
public class ThemeTag extends MessageTag {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2007 the original author or authors.
* Copyright 2002-2022 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.
@ -27,7 +27,7 @@ import org.springframework.web.servlet.ThemeResolver;
* @since 17.06.2003
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public abstract class AbstractThemeResolver implements ThemeResolver {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 the original author or authors.
* Copyright 2002-2022 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.
@ -41,7 +41,7 @@ import org.springframework.web.util.WebUtils;
* @see #setThemeName
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class CookieThemeResolver extends CookieGenerator implements ThemeResolver {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2017 the original author or authors.
* Copyright 2002-2022 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.
@ -35,7 +35,7 @@ import org.springframework.lang.Nullable;
* @see #setDefaultThemeName
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class FixedThemeResolver extends AbstractThemeResolver {
@Override

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2017 the original author or authors.
* Copyright 2002-2022 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.
@ -38,7 +38,7 @@ import org.springframework.web.util.WebUtils;
* @see #setThemeName
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class SessionThemeResolver extends AbstractThemeResolver {
/**

View File

@ -1,5 +1,5 @@
/*
* Copyright 2002-2020 the original author or authors.
* Copyright 2002-2022 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.
@ -33,7 +33,7 @@ import org.springframework.web.servlet.support.RequestContextUtils;
* @see org.springframework.web.servlet.ThemeResolver
* @deprecated as of 6.0, with no concrete replacement
*/
@Deprecated
@Deprecated(since = "6.0")
public class ThemeChangeInterceptor implements HandlerInterceptor {
/**

View File

@ -117,7 +117,7 @@ public abstract class AbstractWebSocketClient implements WebSocketClient {
* @return the established WebSocket session wrapped in a {@code ListenableFuture}.
* @deprecated as of 6.0, in favor of {@link #executeInternal(WebSocketHandler, HttpHeaders, URI, List, List, Map)}
*/
@Deprecated
@Deprecated(since = "6.0")
protected org.springframework.util.concurrent.ListenableFuture<WebSocketSession> doHandshakeInternal(
WebSocketHandler webSocketHandler, HttpHeaders headers, URI uri, List<String> subProtocols,
List<WebSocketExtension> extensions, Map<String, Object> attributes) {

View File

@ -44,7 +44,7 @@ public interface WebSocketClient {
* @return a future that completes when the session is available
* @deprecated as of 6.0, in favor of {@link #execute(WebSocketHandler, String, Object...)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<WebSocketSession> doHandshake(
WebSocketHandler webSocketHandler, String uriTemplate, Object... uriVariables) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(
@ -71,7 +71,7 @@ public interface WebSocketClient {
* @return a future that completes when the session is available
* @deprecated as of 6.0, in favor of {@link #execute(WebSocketHandler, WebSocketHttpHeaders, URI)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<WebSocketSession> doHandshake(
WebSocketHandler webSocketHandler, @Nullable WebSocketHttpHeaders headers, URI uri) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(

View File

@ -211,7 +211,7 @@ public class WebSocketStompClient extends StompClientSupport implements SmartLif
* @return a {@code ListenableFuture} for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(String, StompSessionHandler, Object...)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
String url, StompSessionHandler handler, Object... uriVars) {
@ -244,7 +244,7 @@ public class WebSocketStompClient extends StompClientSupport implements SmartLif
* @return a {@code ListenableFuture} for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(String, WebSocketHttpHeaders, StompSessionHandler, Object...)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
String url, @Nullable WebSocketHttpHeaders handshakeHeaders,
StompSessionHandler handler, Object... uriVariables) {
@ -283,7 +283,7 @@ public class WebSocketStompClient extends StompClientSupport implements SmartLif
* @return a {@code ListenableFuture} for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(String, WebSocketHttpHeaders, StompHeaders, StompSessionHandler, Object...)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
String url, @Nullable WebSocketHttpHeaders handshakeHeaders,
@Nullable StompHeaders connectHeaders, StompSessionHandler handler, Object... uriVariables) {
@ -324,7 +324,7 @@ public class WebSocketStompClient extends StompClientSupport implements SmartLif
* @return a {@code ListenableFuture} for access to the session when ready for use
* @deprecated as of 6.0, in favor of {@link #connectAsync(URI, WebSocketHttpHeaders, StompHeaders, StompSessionHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
public org.springframework.util.concurrent.ListenableFuture<StompSession> connect(
URI url, @Nullable WebSocketHttpHeaders handshakeHeaders,
@Nullable StompHeaders connectHeaders, StompSessionHandler sessionHandler) {

View File

@ -71,7 +71,7 @@ public abstract class AbstractClientSockJsSession implements WebSocketSession {
* Create a new {@code AbstractClientSockJsSession}.
* @deprecated as of 6.0, in favor of {@link #AbstractClientSockJsSession(TransportRequest, WebSocketHandler, CompletableFuture)}
*/
@Deprecated
@Deprecated(since = "6.0")
protected AbstractClientSockJsSession(TransportRequest request, WebSocketHandler handler,
org.springframework.util.concurrent.SettableListenableFuture<WebSocketSession> connectFuture) {
this(request, handler, connectFuture.completable());

View File

@ -45,7 +45,7 @@ public interface Transport {
* @return a future to indicate success or failure to connect
* @deprecated as of 6.0, in favor of {@link #connectAsync(TransportRequest, WebSocketHandler)}
*/
@Deprecated
@Deprecated(since = "6.0")
default org.springframework.util.concurrent.ListenableFuture<WebSocketSession> connect(
TransportRequest request, WebSocketHandler webSocketHandler) {
return new org.springframework.util.concurrent.CompletableToListenableFutureAdapter<>(

View File

@ -46,7 +46,7 @@ public class WebSocketClientSockJsSession extends AbstractClientSockJsSession im
* Create a new {@code WebSocketClientSockJsSession}.
* @deprecated as of 6.0, in favor of {@link #WebSocketClientSockJsSession(TransportRequest, WebSocketHandler, CompletableFuture)}
*/
@Deprecated
@Deprecated(since = "6.0")
public WebSocketClientSockJsSession(TransportRequest request, WebSocketHandler handler,
org.springframework.util.concurrent.SettableListenableFuture<WebSocketSession> connectFuture) {

Some files were not shown because too many files have changed in this diff Show More