Browse Source

Polish

See gh-29114
pull/29136/head
Brian Clozel 2 years ago
parent
commit
c72c2ffc26
  1. 2
      spring-web/src/main/java/org/springframework/web/context/support/AbstractRefreshableWebApplicationContext.java
  2. 2
      spring-web/src/main/java/org/springframework/web/context/support/GenericWebApplicationContext.java
  3. 2
      spring-web/src/main/java/org/springframework/web/context/support/StaticWebApplicationContext.java
  4. 2
      spring-webmvc/src/main/java/org/springframework/web/servlet/DispatcherServlet.java
  5. 2
      spring-webmvc/src/main/java/org/springframework/web/servlet/config/MvcNamespaceUtils.java
  6. 3
      spring-webmvc/src/main/java/org/springframework/web/servlet/support/RequestContext.java
  7. 3
      spring-webmvc/src/main/java/org/springframework/web/servlet/support/RequestContextUtils.java

2
spring-web/src/main/java/org/springframework/web/context/support/AbstractRefreshableWebApplicationContext.java

@ -96,7 +96,6 @@ public abstract class AbstractRefreshableWebApplicationContext extends AbstractR @@ -96,7 +96,6 @@ public abstract class AbstractRefreshableWebApplicationContext extends AbstractR
/** the ThemeSource for this ApplicationContext. */
@Nullable
@Deprecated
private ThemeSource themeSource;
@ -199,7 +198,6 @@ public abstract class AbstractRefreshableWebApplicationContext extends AbstractR @@ -199,7 +198,6 @@ public abstract class AbstractRefreshableWebApplicationContext extends AbstractR
* Initialize the theme capability.
*/
@Override
@Deprecated
protected void onRefresh() {
this.themeSource = UiApplicationContextUtils.initThemeSource(this);
}

2
spring-web/src/main/java/org/springframework/web/context/support/GenericWebApplicationContext.java

@ -86,7 +86,6 @@ public class GenericWebApplicationContext extends GenericApplicationContext @@ -86,7 +86,6 @@ public class GenericWebApplicationContext extends GenericApplicationContext
private ServletContext servletContext;
@Nullable
@Deprecated
private ThemeSource themeSource;
@ -198,7 +197,6 @@ public class GenericWebApplicationContext extends GenericApplicationContext @@ -198,7 +197,6 @@ public class GenericWebApplicationContext extends GenericApplicationContext
* Initialize the theme capability.
*/
@Override
@Deprecated
protected void onRefresh() {
this.themeSource = UiApplicationContextUtils.initThemeSource(this);
}

2
spring-web/src/main/java/org/springframework/web/context/support/StaticWebApplicationContext.java

@ -70,7 +70,6 @@ public class StaticWebApplicationContext extends StaticApplicationContext @@ -70,7 +70,6 @@ public class StaticWebApplicationContext extends StaticApplicationContext
private String namespace;
@Nullable
@Deprecated
private ThemeSource themeSource;
@ -189,7 +188,6 @@ public class StaticWebApplicationContext extends StaticApplicationContext @@ -189,7 +188,6 @@ public class StaticWebApplicationContext extends StaticApplicationContext
* Initialize the theme capability.
*/
@Override
@Deprecated
protected void onRefresh() {
this.themeSource = UiApplicationContextUtils.initThemeSource(this);
}

2
spring-webmvc/src/main/java/org/springframework/web/servlet/DispatcherServlet.java

@ -129,7 +129,7 @@ import org.springframework.web.util.WebUtils; @@ -129,7 +129,7 @@ import org.springframework.web.util.WebUtils;
* Implementations for a fixed theme and for cookie and session storage are included.
* The ThemeResolver bean name is "themeResolver"; default is
* {@link org.springframework.web.servlet.theme.FixedThemeResolver}.
* Theme support is deprecated as of 6.0
* Theme support is deprecated as of 6.0 with no direct replacement.
* </ul>
*
* <p><b>NOTE: The {@code @RequestMapping} annotation will only be processed if a

2
spring-webmvc/src/main/java/org/springframework/web/servlet/config/MvcNamespaceUtils.java

@ -235,7 +235,7 @@ public abstract class MvcNamespaceUtils { @@ -235,7 +235,7 @@ public abstract class MvcNamespaceUtils {
* Registers an {@link FixedThemeResolver} under a well-known name
* unless already registered.
*/
@Deprecated
@SuppressWarnings("deprecation")
private static void registerThemeResolver(ParserContext context, @Nullable Object source) {
if (!containsBeanInHierarchy(context, DispatcherServlet.THEME_RESOLVER_BEAN_NAME)) {
RootBeanDefinition beanDef = new RootBeanDefinition(org.springframework.web.servlet.theme.FixedThemeResolver.class);

3
spring-webmvc/src/main/java/org/springframework/web/servlet/support/RequestContext.java

@ -78,6 +78,7 @@ public class RequestContext { @@ -78,6 +78,7 @@ public class RequestContext {
* Only applies to non-DispatcherServlet requests.
* <p>Same as AbstractThemeResolver's default, but not linked in here to avoid package interdependencies.
* @see org.springframework.web.servlet.theme.AbstractThemeResolver#ORIGINAL_DEFAULT_THEME_NAME
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
public static final String DEFAULT_THEME_NAME = "theme";
@ -389,6 +390,7 @@ public class RequestContext { @@ -389,6 +390,7 @@ public class RequestContext {
/**
* Return the current theme (never {@code null}).
* <p>Resolved lazily for more efficiency when theme support is not being used.
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
public org.springframework.ui.context.Theme getTheme() {
@ -426,6 +428,7 @@ public class RequestContext { @@ -426,6 +428,7 @@ public class RequestContext {
* storing the new theme name through the configured {@link ThemeResolver}.
* @param theme the new theme
* @see ThemeResolver#setThemeName
* @deprecated as of 6.0, with no direct replacement
*/
@Deprecated
public void changeTheme(@Nullable org.springframework.ui.context.Theme theme) {

3
spring-webmvc/src/main/java/org/springframework/web/servlet/support/RequestContextUtils.java

@ -182,6 +182,7 @@ public abstract class RequestContextUtils { @@ -182,6 +182,7 @@ public abstract class RequestContextUtils {
* DispatcherServlet.
* @param request current HTTP request
* @return the current ThemeResolver, or {@code null} if not found
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated
@ -194,6 +195,7 @@ public abstract class RequestContextUtils { @@ -194,6 +195,7 @@ public abstract class RequestContextUtils {
* DispatcherServlet.
* @param request current HTTP request
* @return the current ThemeSource
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated
@ -207,6 +209,7 @@ public abstract class RequestContextUtils { @@ -207,6 +209,7 @@ public abstract class RequestContextUtils {
* @param request current HTTP request
* @return the current theme, or {@code null} if not found
* @see #getThemeResolver
* @deprecated as of 6.0, with no direct replacement
*/
@Nullable
@Deprecated

Loading…
Cancel
Save