Deprecate outdated abstractions/delegates in core/util
Issue: SPR-15159
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2017 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.
|
||||
@@ -23,7 +23,9 @@ package org.springframework.core;
|
||||
*
|
||||
* @author Rod Johnson
|
||||
* @since 02.02.2004
|
||||
* @deprecated as of Spring Framework 4.3.6
|
||||
*/
|
||||
@Deprecated
|
||||
public interface ControlFlow {
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2017 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,9 @@ import org.springframework.util.Assert;
|
||||
* @author Rod Johnson
|
||||
* @author Juergen Hoeller
|
||||
* @since 02.02.2004
|
||||
* @deprecated as of Spring Framework 4.3.6
|
||||
*/
|
||||
@Deprecated
|
||||
public abstract class ControlFlowFactory {
|
||||
|
||||
/**
|
||||
@@ -65,8 +67,8 @@ public abstract class ControlFlowFactory {
|
||||
public boolean under(Class<?> clazz) {
|
||||
Assert.notNull(clazz, "Class must not be null");
|
||||
String className = clazz.getName();
|
||||
for (int i = 0; i < stack.length; i++) {
|
||||
if (this.stack[i].getClassName().equals(className)) {
|
||||
for (StackTraceElement element : this.stack) {
|
||||
if (element.getClassName().equals(className)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -82,9 +84,9 @@ public abstract class ControlFlowFactory {
|
||||
Assert.notNull(clazz, "Class must not be null");
|
||||
Assert.notNull(methodName, "Method name must not be null");
|
||||
String className = clazz.getName();
|
||||
for (int i = 0; i < this.stack.length; i++) {
|
||||
if (this.stack[i].getClassName().equals(className) &&
|
||||
this.stack[i].getMethodName().equals(methodName)) {
|
||||
for (StackTraceElement element : this.stack) {
|
||||
if (element.getClassName().equals(className) &&
|
||||
element.getMethodName().equals(methodName)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -103,7 +105,7 @@ public abstract class ControlFlowFactory {
|
||||
StringWriter sw = new StringWriter();
|
||||
new Throwable().printStackTrace(new PrintWriter(sw));
|
||||
String stackTrace = sw.toString();
|
||||
return stackTrace.indexOf(token) != -1;
|
||||
return stackTrace.contains(token);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2017 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.
|
||||
@@ -25,7 +25,9 @@ package org.springframework.core;
|
||||
*
|
||||
* @author Rod Johnson
|
||||
* @see org.springframework.context.MessageSource
|
||||
* @deprecated as of Spring Framework 4.3.6
|
||||
*/
|
||||
@Deprecated
|
||||
public interface ErrorCoded {
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2017 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,9 @@ import org.apache.commons.logging.LogFactory;
|
||||
* @author Juergen Hoeller
|
||||
* @since 1.2
|
||||
* @see #monitor
|
||||
* @deprecated as of Spring Framework 4.3.6
|
||||
*/
|
||||
@Deprecated
|
||||
public class WeakReferenceMonitor {
|
||||
|
||||
private static final Log logger = LogFactory.getLog(WeakReferenceMonitor.class);
|
||||
|
||||
Reference in New Issue
Block a user